Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
CursorAdapter Closes Tables
Message
De
24/08/2004 13:56:55
 
 
À
24/08/2004 13:16:00
John Fitzgerald
Kenneths Hair Salons & Day Spas,Inc.
Columbus, Ohio, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00936027
Message ID:
00936046
Vues:
31
>I'm working with CursorAdapter to covert a recordset. After I covert it, all the other tables that I have opened before are closed. Anyone know a work around for this.
>

Hi John,

I don't see this behavior with the following code. What am I missing?
CLOSE DATABASES all
SET MULTILOCKS ON 

CREATE CURSOR foo (f1 I)
CREATE CURSOR bar (f2 I)

?AUSED(aU) && prints 2

LOCAL oConn as ADODB.Connection, oRS as ADODB.Recordset

oConn=CREATEOBJECT("ADODB.Connection")
oConn.Open("Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Data Source=(local)")
oRS=oConn.Execute("SELECT * FROM Northwind..Customers")

LOCAL oCA as CursorAdapter

oCA = Createobject("cursoradapter")
cAlias = "TREATMENT"
oCA.DataSourceType="ADO"
oCA.Alias=cAlias
oCA.CursorFill(.F.,.F.,0,oRS)
oCA.CursorDetach()
Release oCA
Release oRS

?AUSED(aU) && prints 3 
Thanks,
Aleksey.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform