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:
00019115
Views:
37
>>> I need to import data from a binary file (*.PDB)
>>> into a VFP DBF. FOPEN() returns a -1 which is
>>> an error so I cannot do it this way. Any ideas?
>>
>>FOPEN has never seen a file it doesn't like. <g>
>>
>>I've been able to open every file you can imagine
>>with FOPEN. Perhaps you really have a small
>>syntax type problem. What is the exact line of
>>code that gives returns a -1 to you?
>>
>>==Carl
>
>Hi Carl,
>
>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.
>
I've gotten around this by uploading a binary file to mainframe and then downloading as binary, so that it gets translated to ascii-- though this may only work if file was created on mainframe, I'm not sure...
The Anonymous Bureaucrat,
and frankly, quite content not to be
a member of either major US political party.
Previous
Reply
Map
View

Click here to load this message in the networking platform