Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Is there a simple way to identify VFP tables?
Message
De
13/10/2003 10:57:31
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00838027
Message ID:
00838111
Vues:
14
>Hi All,
>
>I am looking for a simple way to identify VFP tables. My app can come across several different types such as dBase2 and I want only to be able to open the VFP ones. When I look at the table stru in help I see that first byte is x'30' for VFP. What is the best way to check this from inside of VFP? Any assistance would be most appreciated.
>
>Regards Rex

Rex,
Besides lowlevel functions you could check the header() vs fcount(). VFP tables have an extra 263 bytes backlink space in header. ie:

lVFP = ( (Fcount()+1)*32+263+1 = header() )

or :
lVFP = ( Header() - (Fcount()+1)*32-1 = 263 )

Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform