Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ADO Question
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00616353
Message ID:
00616752
Vues:
25
First, try to add 'Mode=ReadWrite|Share Deny None;' to the connection string. Second, check what type of recordset was created and if it's updatable.

>Next question: I'm getting an error, "The provider is not capable of
>performing the requested operation". The code works fine for retreiving
>records, but errors when I try to Update. My code is:
>
>
>#INCLUDE Ado.h
>
>CLEAR
>
>LOCAL cDataPath, cConnString, oConnection, oRecordSet
>
>cConnString = "Provider=VFPOLEDB.1;Data Source=d:\;"
>oConnection = CREATEOBJECT("ADODB.Connection")
>oConnection.ConnectionString = cConnString
>oConnection.Open()
>
>oRecordSet = CREATEOBJECT("ADODB.RecordSet")
>oRecordSet.ActiveConnection = oConnection
>oRecordSet.CursorType = adOpenDynamic
>oRecordSet.LockType = adLockOptimistic
>
>oRecordSet.Open("Test1")
>
>oRecordSet.MoveFirst
>oRecordSet.Fields(0).Value = "TEST"
>oRecordSet.Update()
>
>
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform