ATOUTFOX
COMMUNAUTÉ FRANCOPHONE DES PROFESSIONNELS FOXPRO
Visual FoxPro : le développement durable

Forum AtoutFox : Re: xbaseEngine et c# ou vb.net   

Sujet

rss Flux RSS des derniers messages

Vous devez vous identifier pour pouvoir poser une question ou répondre.

mar. 24 mars 2009, 12h45
Gregory
atoutfox.public.association

Re: xbaseEngine et c# ou vb.net

Olivier,

J'ai trouve cela quelque part - pas fait de tests

You can simply use a OleDbCommand / -Connection to get data from VFP tables
and write it back into them. It's quite easy and the speed is also
reasonable.

Example for using VFP data inside .NET, opening the whole table:

OleDbConnection conn = new OleDbConnection(@"Data
Source=D:\vfpdev\;Collating Sequence=MACHINE;Provider=VFPOLEDB.1");
OleDbCommand cmd = new OleDbCommand("USE vfptable");
OleDbDataAdapter da = new OleDbDataAdapter(cmd.CommandText, conn);
DataSet ds = new DataSet();
da.Fill(ds);
da.Dispose();
cmd.Dispose();
conn.Dispose();
In this example the DataSet (ds) will contain all rows from the VFP table
similar to the VFP's USE and BROWSE commands. Though the USE command opens
the VFP table it can still be opened EXCLUSIVE from VFP, it doesn't lock the
table.


Gregory
_
"OlivierH" <"nospam[contact]"@planitron.com> wrote in message
news:gqaeg3$1a4v$1@news.niouzes.net...
> Bonjour
>
> En cherchant le moyen de créer des dbf sous .Net je suis tombé sur une
> librairie qui peut aider certains d'entre nous.
>
> http://www.c-sharpcorner.com/UploadFile/rfederico/xBaseEngineRFV12022005011623AM/xBaseEngineRFV.aspx
>
> Le hic c'est que cela semble lire de vieux fichier dbf. (et pas de memo ni
> de cdx)
>
> Olivier,

--
Gregory
__
Permalink : http://www.atoutfox.org/nntp.asp?ID=0000002836
20 286 messages dans le forum • Liste complète des messages

www.atoutfox.org - Site de la Communauté Francophone des Professionnels FoxPro - v3.4.0 - © 2004-2026.
Cette page est générée par un composant COM+ développé en Visual FoxPro 9.0-SP2-HF3