Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Lock and unlock record in vfp
Message
De
21/07/2015 02:41:30
 
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Versions des environnements
Environment:
C# 4.0
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01622274
Message ID:
01622311
Vues:
45
>Hi all,
>
>we have a small prg in VFP that generates a key from a table, works perfectly in VFP. I'm now starting to work in .Net and need to get the net available number in the table and replace the existing number with original + 1. The table that stores the keys is a frequently used VFP table so I do need locking in order to ensure that I don't duplicate keys.
>How do I go about this via C# in .Net?

IIRC, a couple of options.
The OLEDB provider supports VFP's LOCK() so you could build up a bit of VFP code and use ExecuteNonQuery().
Something like : http://stackoverflow.com/questions/16343342/oledb-foxpro-lock-record
Or, if you have VFP installed, you can run a VFP stored proc : https://support.microsoft.com/en-us/kb/299820
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform