|
|
|
| Hi Everyone
ive had a corrupted table and used a hex editor to recover the data into a
text file
all of the data now appears in the txt file, however ther are no carrage
returns it is all in a single line.
is ther any way or program which i can use to add carrage returns so that i
can import the file into a dbase table
Regards Peter
| |
| Bowen Moursund [DataTech] 2006-02-06, 1:23 pm |
| > ive had a corrupted table and used a hex editor to recover the data into a
> text file
>
> all of the data now appears in the txt file, however ther are no carrage
> returns it is all in a single line.
>
> is ther any way or program which i can use to add carrage returns so that
> i
> can import the file into a dbase table
If the 'records' in the text file all are all the same length:
nRecordLen = {whatever it is}
oIn = new file()
oOut = new file()
oIn.open("TheTextFile.txt")
oOut.create("TheOutputFile.sdf")
do
oOut.write( oIn. read(nRecordLen)+chr
(13)+chr(10) )
until not oIn.eof()
oIn.close()
oOut.close()
--
Bowen Moursund
DataTech
Consulting & Development
http://www.bmmnet.us
| |
|
| Hi Bowen
Thanks for the reply. Ive tried this and the program runs but only copies 1
record poss something else required on the do loop ?
Regards Peter
| |
| Bowen Moursund [DataTech] 2006-02-07, 9:23 am |
| > Thanks for the reply. Ive tried this and the program runs but only copies
> 1
> record poss something else required on the do loop ?
Change 'until not oIn.eof()' to 'until oIn.eof()'.
--
Bowen Moursund
DataTech
Consulting & Development
http://www.bmmnet.us
| |
|
| Hi Bowen
yes that worked great
thanks a lot
sayed me hours of work
regards Peter
|
|
|
|