Jump to content

BruceV

Members
  • Content Count

    5
  • Joined

  • Last visited

Community Reputation

0 Neutral
  1. This is a mea culpa. I tested the suggested WIN32 alternative in a different project, and referenced a different .txt file. that worked. That raised suspicions, so I carefully inspected the .txt files I was trying to open. Somehow, the one that didn't work had had a second .txt appended, ie. it was testfile.txt.txt. The way that Windows displays file, that was not obvious, it was only when I checked the situation in a command window that the situation became clear. So my original code did work, when pointed at the correct filename. In hindsight, both responses to my post were of assistance, in generating enough doubt for me to relook at things. I also thought it important to exonerate the platform. Apologies for posting before investigating thoroughly.
  2. Thanks Remy for the extremely useful response. Your first suggestion threw up 40 (!) linker errors which are all way above my pay grade, and I wouldn't trouble you to go anywhere with them. The second one, the standard WIN32 approach, works fine and will do what I want. So thanks again! If I ever find out why my initial approach isn't working, I'll post the details.
  3. Hello, I have recently installed and registered C++ builder CE, my first test program is not behaving correctly. It's a trivial C++ program, the file open fails. There is nothing that I can see that is incorrect, I've coded with files for decades. Any suggestions appreciated. #include <iostream> #include <fstream> #include <conio.h> #include <tchar.h> using namespace std ; ifstream ifs ; int _tmain(int argc, _TCHAR* argv[]) { ifs.open ("C:\\Junk\\testfile.txt") ; if (!ifs.good()) // ** Also tried if (!ifs) { cout << "Can't open input file.\n"; while (!kbhit()) ; return 1 ; } cout << "Opened OK\n" ; ifs.close() ; while (!kbhit()) ; return 0 ; }
  4. Hello, I have been using XE5 for many years, it has outlasted 3 machines. For the last two times I've simply reinstalled successfully, but this 3rd time I've come up against the install limit error, the registration failed. Is there a way that I can reset the active instance count given the situation, I accept that that request may be met with some scepticism. I can't think of any way to objectively demonstrate that there are no other instances in existence.
  5. Apologies in advance for this being probably OT. I am trying to register an installation of C++ builder XE-5 that I have just reinstalled following a machine failure. My credentials for these forums were many years old, and my email address has changed so I have just set up another account for this forum, it seemed the most appropriate. However, when I enter these new credentials into the XE5 license registration form it advises that they are not recognised. Having registered for this forum, are the credentials applicable for all Embarcadero forums? Forum credentials entry is required for product registration. The licence key I have is valid.
×