i would look into "Header" of *.DAT
Code: Select all
nHandle := FOPEN( cDbf )
FSEEK( nHandle, 0, 0 ) // Move pointer to first byte
FREAD( nHandle, @cBuffer, 1 )
FCLOSE( nHandle )
nType := ASC( cBuffer )
DO CASE
CASE nType = 2 // 02h FoxBASE
CASE nType = 3 // 03h FoxBASE+/Dbase III plus, no memo
CASE nType = 4 //* 04h dbase IV without memofile
CASE nType = 5 //* 05h dbase V without memofile
CASE nType = 7 //* 07h visual object for dbase III without memofile
CASE nType = 48 // 30h Visual FoxPro
CASE nType = 49 // 31h Visual FoxPro, autoincrement enabled
CASE nType = 67 // 43h dBASE IV SQL table files, no memo
CASE nType = 99 // ???
CASE nType = 123 //* 7Bh "dbase IV with memo
CASE nType = 131 // 83h FoxBASE+/dBASE III PLUS, with memo
CASE nType = 135 //* 87h visual object for dbase III with memofile
CASE nType = 139 // 8Bh dbase IV with memo
CASE nType = 142 //* 8Eh dbase IV with SQL table
CASE nType = 179 //* B3h .dbv memo and dbt memo flagship
CASE nType = 203 // 0xCB dBASE IV SQL table files, with memo
CASE nType = 229 //* E5h HiPer-Six format with SMT memo file
CASE nType = 245 // F5h FoxPro 2.x (or earlier) with memo
CASE nType = 251 // FBh FoxBASE
ENDCASE