Author | Topic: open cdx foxpro | |
---|---|---|
rousseau alain | open cdx foxpro on Mon, 12 Aug 2013 21:25:09 +0200 Hi I work in Xbas an I would like open existing DBF in foxpro (I use dbesys.prg to switch in Foxpro dbf and CDX) I haven't source program in Xbase and I can't open the cdx of a dbf foxpro the dbf is wstock1.dbf and in the same directory I have a wstock1.cdx I can't open the dbf but I can't use the cdx What is the xbase command I use this reseau("h:\gcipv2\data\wstock1.dbf",.f.,0) Cfile := "h:\gcipv2\data\kan_cbf.cdx" *index on cbf to (Cfile) set index to (Cfile) It's possible to have many index in a same cdx xbase : set index to index1, index2 Foxpro : set index to index 1 tag .... ???? after how I use the correct index If this syntax is correct how to know the list of index key in the cdx if your are not the programmer ? Sorry to poor english thanks alain | |
Peter Alderliesten | Re: open cdx foxpro on Mon, 12 Aug 2013 21:53:27 +0200 Alain, > I work in Xbas an I would like open existing DBF in foxpro > (I use dbesys.prg to switch in Foxpro dbf and CDX) > > I haven't source program in Xbase and > I can't open the cdx of a dbf foxpro > > the dbf is wstock1.dbf and in the same directory I have > a wstock1.cdx > > I can't open the dbf but I can't use the cdx > > What is the xbase command > I use this > > reseau("h:\gcipv2\data\wstock1.dbf",.f.,0) > Cfile := "h:\gcipv2\data\kan_cbf.cdx" > *index on cbf to (Cfile) > set index to (Cfile) > > It's possible to have many index in a same cdx > > xbase : set index to index1, index2 > > Foxpro : set index to index 1 tag .... ???? > after how I use the correct index > If this syntax is correct how to know the list of index key in the cdx > if your are not the programmer ? > Could you check if there is/was an order active after you opened the file? The .cdx file is not automatically opened with Xbase++ You have to: ordListAdd(cIndexFile) and then specify an order. Xbase++ supports FoxPro files so it should be a problem. Peter | |
Peter Alderliesten | Re: open cdx foxpro on Tue, 13 Aug 2013 08:59:12 +0200 > Xbase++ supports FoxPro files so it should be a problem. ... should be NO problem. | |
news alaska software | Re: open cdx foxpro on Tue, 13 Aug 2013 17:39:46 +0200 thanks Peter We have a software to make the cashdrawer (it's the right word !) This soft is write in FOXPRO and the motor is Borland engine .... It's not very fast !! and I would like pick up some informations in the BD with a program write in Xbase. I have made a soft and I don't understand to open cdx in foxpro reseau(drive + ":\gcipv2\data\wstock1.dbf",.f.,0) *** this function is netuse bur en francais Cfile := drive + ":\gcipv2\data\w_stock1.cdx" set index to (Cfile) I use this, and I have an error when the program execute "set index" message of error (alaska1.jpg) : unknown variable !!! code_couleur after I click on "annuler" message error again (alaska2.jpg) File can't be opened OrdlistAdd no generation of xpperror.log idem to xppfatal.log It's possible to have an example in Foxpro open, index, and set index Thanks a lot alaska2.jpg alaska1.jpg | |
Peter Alderliesten | Re: open cdx foxpro on Wed, 14 Aug 2013 09:25:25 +0200 Alain, > It's possible to have an example in Foxpro > open, index, and set index lOpen := .f. cFile := cDrive + ":\gcipv2\data\w_stock1 cAlias := "w_stock1" cOrder := "myOrder" dbUseArea(.t.,, cFile, cAlias, .t.) open shared if ! neterr() check if file is open lOpen := .t. ordListAdd(cFile) ordSetFocus(cOrder) endif return lOpen Could you set the value of cOrder to the name of the required tag and test this with the debugger. You could check there ordname() as well to see if the correct order is set. Peter | |
news alaska software | invalid user name on Tue, 13 Aug 2013 17:48:22 +0200 oups I little mistake to the user name it's not news.alaska-software !! sorry | |
Pascal Boivin | Re: open cdx foxpro on Wed, 14 Aug 2013 14:32:26 +0200 Hi You should show us your DbeSys functions. Maybe there is something wrong in there. | |
Rousseau ALain | Re: open cdx foxpro on Wed, 14 Aug 2013 15:29:45 +0200 Bonjour Pascal Je pense que Dbesys.prg est correct : Procedure dbesys() IF ! DbeLoad( "FOXDBE", .T.) Alert( "FOXDBE not loaded", {"OK"} ) ENDIF IF ! DbeLoad( "CDXDBE", .T.) Alert( "CDXDBE not loaded", {"OK"} ) ENDIF IF ! DbeBuild( "FOXCDX", "FOXDBE", "CDXDBE" ) Alert( "Unable to build;" + ; "FOXCDX DatabaseEngine" , {"OK"} ) ENDIF DbeSetDefault( "FOXCDX" ) Mais attention je travaille en mixte dbf et foxpro et j'utilise dbfsetdefault pour passer d'un à l'autre ! Merci "Pascal Boivin" a écrit dans le message de groupe de discussion : xn0ilsu1227fd9000@news.alaska-software.com... > Hi > > You should show us your DbeSys functions. Maybe there is something > wrong in there. | |
Pascal Boivin | Re: open cdx foxpro on Wed, 14 Aug 2013 16:26:06 +0200 Anyone out there using FoxDbe know what are the right DbeInfo settings for Alain? From the help file, it should look like these below. DbeInfo( COMPONENT_DATA, FOXDBE_CREATE_2X, .F. ) DbeInfo( COMPONENT_DATA, FOXDBE_LOCKMODE , FOXDFBE_LOCKMODE_VISUAL )DbeInfo(COMPONENT_ORDER, CDXDBE_MODE, CDXDBE_VFOXPRO) Je n'utilise pas FoxDbe alors je ne connais pas les options spécifique, mais habituellement il y a des trucs comme ceci à ajouter dans ton DbeSys. Regarde dans "FOXDBE" et "CDXDBE" dans l'aide. Pour avoir le plus de réponses possible, vaut mieux continuer en anglais car il y a beaucoup d'Allemands et autre! | |
Carlos A Beling | Re: open cdx foxpro on Wed, 14 Aug 2013 12:10:17 -0300 Hello: good morning. Attached is the DBf that I use. Beling HTH Em 14/8/2013 11:26, Pascal Boivin escreveu: > Anyone out there using FoxDbe know what are the right DbeInfo settings > for Alain? > From the help file, it should look like these below. > > DbeInfo( COMPONENT_DATA, FOXDBE_CREATE_2X, .F. ) > DbeInfo( COMPONENT_DATA, FOXDBE_LOCKMODE , FOXDFBE_LOCKMODE_VISUAL > )DbeInfo(COMPONENT_ORDER, CDXDBE_MODE, CDXDBE_VFOXPRO) > > Je n'utilise pas FoxDbe alors je ne connais pas les options spécifique, > mais habituellement il y a des trucs comme ceci à ajouter dans ton > DbeSys. Regarde dans "FOXDBE" et "CDXDBE" dans l'aide. Pour avoir le > plus de réponses possible, vaut mieux continuer en anglais car il y a > beaucoup d'Allemands et autre! > DBESYS.PRG | |
Peter Alderliesten | Re: open cdx foxpro on Wed, 14 Aug 2013 19:35:33 +0200 Pascal, > From the help file, it should look like these below. > > DbeInfo( COMPONENT_DATA, FOXDBE_CREATE_2X, .F. ) This depends on the Foxpro file version you are working with. This creates the lowest compatible FoxPro file. If you are working with Visual Foxpro files, you should comment out this line. Peter | |
rousseau alain | Re: open cdx foxpro on Thu, 15 Aug 2013 22:47:06 +0200 Hello to all Thank you for your answers I do not still find the solution !!! I used Carlos's dbesys.prg ( thanks Carlos) With the software of Management of Stock, the supplier gave us Dot9.exe I have verified de version of Visual FoxPro 9.00 Our supplier uses this program to reach in Database to correct certain problems. Otherwise our program of Stock is in .EXE I used Dot9 to open the BD WSTOCK1 J'ai introduit use c:\data\wstock1 set index to c:\data\wstock1 set order to cbf brow indexation on "code barre" That works !! set order to libelle brow That works !! From moment or I program it in xBase The program stop at the opening of the file cdx with this error first window Erreur Base/2000 Description : unknown variable Operation : CODE_COULEUR Thread ID 1 Facturation(128) I click on "Annuler" second window Erreur Base/2000 Description : File can not be opened Operation : OrdlistAdd Thread ID 1 Facturation(128) Remark: the variable code_couleur does not exist Only a field of the BD wstock1 looks like: CODE_coule 2 Windows open for errors on the line 128 to the opening of the file index File not found I can open the BD wstock and I create new index to consult data But if I want to change keys of index, the original program is going to have bugs. Still have you ideas to help me Thanks to you all Alain "rousseau alain" <joueclub@joueclub-perpignan.fr> a écrit dans le message de groupe de discussion : c20141f$40c26518$7ce0@news.alaska-software.com... > Hi > I work in Xbas an I would like open > existing DBF in foxpro > (I use dbesys.prg to switch in Foxpro dbf and CDX) > > I haven't source program in Xbase and > I can't open the cdx of a dbf foxpro > > the dbf is wstock1.dbf and in the same directory I have > a wstock1.cdx > > I can't open the dbf but I can't use the cdx > > What is the xbase command > I use this > > reseau("h:\gcipv2\data\wstock1.dbf",.f.,0) > Cfile := "h:\gcipv2\data\kan_cbf.cdx" > *index on cbf to (Cfile) > set index to (Cfile) > > It's possible to have many index in a same cdx > > xbase : set index to index1, index2 > > Foxpro : set index to index 1 tag .... ???? > after how I use the correct index > If this syntax is correct how to know the list of index key in the cdx > if your are not the programmer ? > > > Sorry to poor english > > > thanks > > alain > > > | |
Carlos A Beling | Re: open cdx foxpro on Fri, 16 Aug 2013 09:33:51 -0300 Hello Rousseau: good morning. It has a problem when you indexes a database with a field that does not exists. I think you must dlete all indexes and reindex fot to have sure that everything is ok. Beling HTH Em 15/8/2013 17:47, rousseau alain escreveu: > Hello to all > > Thank you for your answers > I do not still find the solution !!! > I used Carlos's dbesys.prg ( thanks Carlos) > With the software of Management of Stock, the supplier gave us Dot9.exe > I have verified de version of Visual FoxPro 9.00 > Our supplier uses this program to reach in Database to correct certain > problems. > Otherwise our program of Stock is in .EXE > > I used Dot9 to open the BD WSTOCK1 > J'ai introduit > > use c:\data\wstock1 > set index to c:\data\wstock1 > set order to cbf > brow > indexation on "code barre" > That works !! > set order to libelle > brow > That works !! > From moment or I program it in xBase > The program stop at the opening of the file cdx > with this error > > first window > > Erreur Base/2000 > Description : unknown variable > Operation : CODE_COULEUR > Thread ID 1 > Facturation(128) > > I click on "Annuler" > > second window > > Erreur Base/2000 > Description : File can not be opened > Operation : OrdlistAdd > Thread ID 1 > Facturation(128) > > Remark: the variable code_couleur does not exist > Only a field of the BD wstock1 looks like: CODE_coule > > 2 Windows open for errors on the line 128 to the opening of the file index > File not found > > I can open the BD wstock and I create new index > to consult data > But if I want to change keys of index, the original program is going to > have bugs. > Still have you ideas to help me > > Thanks to you all > > Alain > > > > "rousseau alain" <joueclub@joueclub-perpignan.fr> a écrit dans le > message de groupe de discussion : > c20141f$40c26518$7ce0@news.alaska-software.com... >> Hi >> I work in Xbas an I would like open >> existing DBF in foxpro >> (I use dbesys.prg to switch in Foxpro dbf and CDX) >> >> I haven't source program in Xbase and >> I can't open the cdx of a dbf foxpro >> >> the dbf is wstock1.dbf and in the same directory I have >> a wstock1.cdx >> >> I can't open the dbf but I can't use the cdx >> >> What is the xbase command >> I use this >> >> reseau("h:\gcipv2\data\wstock1.dbf",.f.,0) >> Cfile := "h:\gcipv2\data\kan_cbf.cdx" >> *index on cbf to (Cfile) >> set index to (Cfile) >> >> It's possible to have many index in a same cdx >> >> xbase : set index to index1, index2 >> >> Foxpro : set index to index 1 tag .... ???? >> after how I use the correct index >> If this syntax is correct how to know the list of index key in the cdx >> if your are not the programmer ? >> >> >> Sorry to poor english >> >> >> thanks >> >> alain >> >> >> | |
Pascal Boivin | Re: open cdx foxpro on Fri, 16 Aug 2013 16:39:34 +0200 Hi Old clipper allow field name with more than 10 caracters, but only the first 10 are saved. It looks like Foxpro is doing the same thing. This means you can have a field named CODE_COULE in the DBF, CODE_COULEUR in the CDX, and CODE_COULEUR_DU_CIEL in software. XBase doesn't allow that. I'm pretty sure you can rebuild the CDX with "CODE_COULE" and the original Foxpro software will still recognize it. | |
Rousseau ALain | open cdx foxpro on Sat, 17 Aug 2013 11:40:01 +0200 Hi Pascal CODE_COULE in the bdf foxpro : Yes CODE_COULEUR in the cdx foxpro :NO CODE_COULEUR_nimportequoi in foxpro soft : I don't know Hello has all I tried all your ideas But unsuccessfully I am blocked on this unknown variable CODE_COULEUR PFF Ras le bol en français I also tried the reindexation as Carlos said I made him(it) with the original program in Foxpro but unsuccessfully Thanks a lot "Pascal Boivin" a écrit dans le message de groupe de discussion : xn0ilvqi16qwjy000@news.alaska-software.com... > Hi > > Old clipper allow field name with more than 10 caracters, but only the > first 10 are saved. It looks like Foxpro is doing the same thing. > > This means you can have a field named CODE_COULE in the DBF, > CODE_COULEUR in the CDX, and CODE_COULEUR_DU_CIEL in software. > > XBase doesn't allow that. I'm pretty sure you can rebuild the CDX with > "CODE_COULE" and the original Foxpro software will still recognize it. | |
James Loughner | Re: open cdx foxpro on Sun, 18 Aug 2013 01:11:25 -0400 Reindex in Xbase++ Should work in FoxPro also the problem is a field name with more then 10 characters. I have no idea where it is coming from but it is there and confusing Xbase++ which a little more strict then FoxPro about field naming Jim On 08/17/2013 05:40 AM, Rousseau ALain wrote: > Hi Pascal > > CODE_COULE in the bdf foxpro : Yes > CODE_COULEUR in the cdx foxpro :NO > CODE_COULEUR_nimportequoi in foxpro soft : I don't know > > > Hello has all > I tried all your ideas > But unsuccessfully > I am blocked on this unknown variable > CODE_COULEUR > > PFF Ras le bol en français > > I also tried the reindexation as Carlos said > I made him(it) with the original program in Foxpro but unsuccessfully > > Thanks a lot > > > > "Pascal Boivin" a écrit dans le message de groupe de discussion : > xn0ilvqi16qwjy000@news.alaska-software.com... >> Hi >> >> Old clipper allow field name with more than 10 caracters, but only the >> first 10 are saved. It looks like Foxpro is doing the same thing. >> >> This means you can have a field named CODE_COULE in the DBF, >> CODE_COULEUR in the CDX, and CODE_COULEUR_DU_CIEL in software. >> >> XBase doesn't allow that. I'm pretty sure you can rebuild the CDX with >> "CODE_COULE" and the original Foxpro software will still recognize it. > |