Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
FPD25 DBF headers and Year 2003
Message
General information
Forum:
Visual FoxPro
Category:
FoxPro 2.x
Miscellaneous
Thread ID:
00738059
Message ID:
00739683
Views:
16
Thanks Sergey, in fact I was hoping you would notice my post and you did.

>The second byte of the table header is the year of the last update. Both 02 and 03 are valid table types
0x02   FoxBASE
>0x03   FoxBASE+/Dbase III plus, no memo
Switching 1 and 2 bytes in this case may not make table header invalid but my change table type. You'll have to come up with another way to protect your tables.

It did not happen last year but this year created hell.

>Pack creates new temp. table, copies record there, dletes original table and renames temp. table back to the name of original table. It doesn't correct header, it creates new correct one.

This explains my observation as at a clients place I configured my app to keep dbfs unlocked as well as pack on close and the problem went away.

Thanks, you may not be able to guess how problematic this was turning out to be, I had visions that I might have to leave this field of work <g> and your help is really appreciated. And because it was happening with my main app, more users were affected.

>
>
>
>>Hi Sergey
>>
>>I guess I know the problem but am not sure.
>>
>>>What did you correct in the table header to get it to work again?
>>The header file is simply an empty DBF renamed to HDR and in code I overwrite the bytes without touching the date-time bytes and then correcting the record counter manually.
>>
>>The problem and maybe solution lies here:
>>
>>I was locking the DBF by switching the first 2 byte, ie byte 1 becomes byte 2 and byte 2 becomes byte one so that novices can't open the dbf in foxpro and modify whatever they please.
>>
>>When unlocking I use the dbf and if I can't use it I switch the bytes and try using it again and generally this was successful.
>>
>>Now hat happens is that even if the dbf is locked the use command succeeds and the dbf is given for regular opening and when this dbf is opened all sorts of unknown problem crop up. These dbf's have memo fields, in fact almost all of the dbfs have memo fields in this app. Surprisingly, none of my other apps seems to be having this problem, just this my flagship products used by lots of people.
>>
>>Right now I have stopped the locking and it looks okay. Also in such a dbf ie. locked but still usable running PACK on it seemd to solve this problem, does PACK change headers?
>>
>>Thanks for responding and I couldn't respond earlier as I had my handsful with this problem.
>>
>>Any suggestions.
>>
Regards
Bhavbhuti
___________________________________________
Softwares for Indian Businesses at:
http://venussoftop.tripod.com
___________________________________________
venussoftop@gmail.com
___________________________________________
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform