Greetings,
I need to save the results of a test procedure that
returns HEX data from a memory read, I wan't to be able
to enter the name of the output file (data.txt). I used
an Edit object to get the filename (which is an AnsiString),
when I use the CreateFile function, it requires an char * as an handler.
I converted the string using the c_str() method. Now i get a bold pipe character '|' at the end of my handler:
LPCTSTR OutputFile = EDIT_OutputFile->Text.c_str();
I'd like to know how to get rid of this unwanted character
(the file won't create because of it) or if there's a technique that can check and increment the filename if it
already exists (as in data1.txt, data2.txt, ...)
Simon Lapierre
slapierre@sonomax.com
I need to save the results of a test procedure that
returns HEX data from a memory read, I wan't to be able
to enter the name of the output file (data.txt). I used
an Edit object to get the filename (which is an AnsiString),
when I use the CreateFile function, it requires an char * as an handler.
I converted the string using the c_str() method. Now i get a bold pipe character '|' at the end of my handler:
LPCTSTR OutputFile = EDIT_OutputFile->Text.c_str();
I'd like to know how to get rid of this unwanted character
(the file won't create because of it) or if there's a technique that can check and increment the filename if it
already exists (as in data1.txt, data2.txt, ...)
Simon Lapierre
slapierre@sonomax.com