Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is Connection Handle Valid?
Message
From
01/11/2005 21:39:58
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01064317
Message ID:
01064328
Views:
27
Hello,

you may check this reading some connection setting with SQLGETPROP and catching
the error if the handle is not valid
e.g.
FUNCTION IsConnectionValid(lnConHandle)
LOCAL lbValid
lbValid = .T.
TRY
 SQLGETPROP(lnConHandle,'ConnectBusy')
CATCH TO loError WHEN loError.ErrorNo = 1466 && Connection handle invalid error
   lbValid = .F.
ENDTRY
RETURN lbValid
ENDFUNC
Regards
Christian
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform