>Greetings -
>
>What's the best way to tell--without first openning, if at all possible--the type of DBF (Fox2X v. Visual) you are dealing with? It's a long story, but I need to be able to tell the type of file it is so I know whether I can "poke" at the DBF Header and determine what the DBF's DBC backlink is. Seems in non-Visual Tables the utility I am using to get that info just returns actual data from the DBF.
>
>Thanks!
>________________
>_____/ Regards,
>____/ al
>___/
>__/
>_/
>/
This is documented in help, under Using Visual FoxPro | Programmer's Guide | Appendix | Table File Structure.
It seems the very first byte indicates the file type.
You can get at this information with low-level file-functions (in this case, you will need fopen(), fread() and fclose()).
HTH, Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)