Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Import a binary file into VFP.
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00019096
Message ID:
00019382
Views:
58
>>>>>>I've never run into a problem with FOPEN either
>>>>>>until now. I have a file called phone1.pdb on
>>>>>>a diskette. I used lnFile = FOPEN("A:\PHONE1.PDB",10)
>>>>>>and also tried lnFile = FOPEN("A:\PHONE1.PDB")
>>>>>>
>>>>>>Both gave a -1 lnFile value which is an error. That's
>>>>>>why I posted the message. In VFP 5.0's help under
>>>>>>"binary", it says that a binary file can only be read
>>>>>>by the application that created it.
>>>>>>
>>>>>
>>>>>What system or app is creating that file, "PHONE1.PDB"?
>>>>>
>>>>I don't know what app created the *.pdb file but I do know the
>>>>person running it is using a PC with Win95. I've never seen
>>>>the extension before. At first I thought it was Paradox, but I
>>>>guess not as VFP could have imported that directly.
>>>>
>>>I'd seen them before so I poked around in C files...
>>>It's a C++ file containing project debugging info in binary. I'm not sure why anyone would want to export it elsewhere...
>>
>>could also be powerbuilder (of course, i haven't looked at that for 3 years, so i'm not sure...)
>
>yeah, I guess it could be...either way, it won't be much use in FP, it would seem...I'd check the source of the file to get more info.

MUCH APPRECIATION to all the folks who responded to my question. The
file in question comes from a contact mgr app. I've written one in VFP
for the gentleman who supplied that disk from his existing contact mgr
app. I and neither does he, know what the software is, he just runs it.
He didn't want to have to reload the data into his new software so he
gave me the disk. I have since managed to open and read it via fopen
and fread, but only from the harddrive, fopen still errors when trying
to read the file directly from the A drive. I don't know why that is and
it doesn't matter anymore.

Thanks again,
Steve Despres
Previous
Reply
Map
View

Click here to load this message in the networking platform