PDA

View Full Version : converting dbf in visual foxpro 6.0 to foxpro 2.6


rsk_beckon
07-28-07, 03:54
Hai All

I am developing an application using visual foxpro 6 as backend. But my customer is using dos based foxpro 2.6.

Whether my .dbf and .fpt(memo) in vfpx 6.0 will directly open in 2.6 dbf or else i want to do any conversion?

whether this backward Compatibility works?

If i need to convert it, then how to do it.

Reply reply. Its urgent

tod.mckenna
07-28-07, 07:53
You will be able to open the Fox 2.6 tables in VFP6 without problem. You can even use the "COPY TO" command to copy cursors or other files created in VFP6 to the Fox2.6 version:

USE customer && Opens Customer table
COPY TO sometable TYPE FOX2X

But do not use Alter Table (or the MODIFY STRUCTURE) command from VFP6, otherwise FoxPro will save the table in the new format. Either make structural changes in Fox2.6 or use COPY TO TYPE FOX2X when done.

You should also be aware of new field types (Currency, DateTime, Double, and Integer) that do not exist in Fox26.

If I remember correctly (it's been a while since I've opened Fox26 tables in a VFP production environment), you may get codepage dialogs whenever you try to open the Fox26 tables from VFP6. If you do, then you can skirt around this by looking into the SET CPDIALOG Command (and related functions). Codepage translation is important, so be careful before you decide to just shut this off!

rsk_beckon
07-28-07, 08:10
Thanks for given me the suggestion. Now my original table ie.vfpx 6.0 contains nearly 20 fields. I have included my own fields for validation, but i need only certain fields which is useful for customer to be sent.

So i need to create another table with the same name and copy only the fields that are necessary for the customer and dropping other fields and send this to our customer so that they can directly upload to their dbf. I am using vb 6.0 as front end.

How i have to code in vb for this particular case. I am also using .fpt for a memo field. whether it is possible to code in visual foxpro directly. I dont know much about foxpro commands. If anyone knows, Please suggest me.

tod.mckenna
07-28-07, 08:15
Simple.

Just use the COPY TO command and include the FIELDS clause along with TYPE FOX2X.


USE customer && Opens Customer table
COPY TO sometable FIELDS field1, field2, field3 TYPE FOX2X

byrman
10-16-07, 00:13
yes, copy to xxxxxxxx type foxplus...................

hndubey
11-06-07, 05:54
you will have to convert your vfp 6 dbf file into 2.6 foxpro
the command is :
in command window - vfp 6.0
USE ABC
COPY TO BCD TYPE FOX2X

The file bcd.dbf can be use in foxpro 2.6

Hai All

I am developing an application using visual foxpro 6 as backend. But my customer is using dos based foxpro 2.6.

Whether my .dbf and .fpt(memo) in vfpx 6.0 will directly open in 2.6 dbf or else i want to do any conversion?

whether this backward Compatibility works?

If i need to convert it, then how to do it.

Reply reply. Its urgent