Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
What causes conncection handle invalid error
Message
De
01/11/2002 17:29:15
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
What causes conncection handle invalid error
Divers
Thread ID:
00718055
Message ID:
00718055
Vues:
61
Ooops, I think I accidently clicked on the send button before I could finish my thread last time. Here is the complete question:

HELP!!! Very frequently, as I ran my program (mainly a screen with pageframe, about 5 pages on the page frame), move from 1 record to another, then logout (I did not even do anything else); as I ran the progam the 2nd time, as the form class loads (as it execute: CLOSE DATA ALL), I get "connection handle invalid" error. Once that happens, I basically need to force VFP to quit (end task) & restart VFP. Typing CLOSE DATA ALL on the command window will give me the same error. Can anybody give me a hint on what to check?


myForm.Load():

CLOSE DATA ALL
lcConnStrAUSD="DRIVER={Microsoft Visual FoxPro Driver};" + ;
"SourceDB=C:\Projects\mydata.dbc;SourceType=DBC;UID=;PWD=;"

THIS.lnHandle=SQLSTRINGCONNECT(lcConnStrAUSD)

IF THIS.lnHandleERCA>0
lSuccess=SQLEXEC(THIS.lnHandleERCA,"SELECT * FROM myData","cMyData")
IF lSuccess=1
SET MULTILOCKS ON
CURSORSETPROP('Buffering',3,'cMyData')
CURSORSETPROP('TABLES','erca','cERCA')
CURSORSETPROP('UPDATABLEFIELDLIST','myField','cMyData')
CURSORSETPROP('KeyFieldList','myField','cMyData')
CURSORSETPROP('UpdateNameList','myField,'cMyData')
CURSORSETPROP('FetchMemo',.T.,'cMyData')
CURSORSETPROP('SendUpdates',.T.,'cERCA')
ENDIF
ENDIF


myForm.Unload()
*(as user clicks LogOut)
lSuccess=SQLDISCONNECT(THIS.lnHandle)
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform