Hi Farouk,
When the FOpen() function opens a file successfully it returns a filehandle for the file but returns -1 when the file in question can't be opened.
There are various reasons that files can't be opened including: the file doesn't exist, the user doesn't have permissions or that it is already opened by someone else, etc.
Here's more information regarding the FOpen() function:
http://msdn.microsoft.com/library/en-us/fox7help/html/lngfopenlp_rp.asp?frame=trueGood luck!!!
Hugh
>Hi,
>
>I have a function which uses fopen() to open some dbf files. At my place, everything is working fine but in client's place some of this file cannot be opened (return -1). What could be the reason? My user is using Wins98 OS...
>
>Regards.
Microsoft hears loudest what the VFP community says about Visual FoxPro by looking at the bottom line!
Support the product. Buy the latest version!
Hugh Winters @ WorldData 408-512-1131