Set objCon = CreateObject("ADODB.Connection")
On Error Resume Next
connectionstring = "Provider=SQLOLEDB;Server=" & Server_Name &
";Trusted_Connection=No;Initial Catalog=" & db_Instance & ";User ID="
& User_name & ";Password=" & Password & ";"
objCon.Open connectionstring
If Not (Err.Number = 0) Then
MsgBox "Error Code : " & Err.Description
ExitFlag = 0
Exit Sub
Else
ExitFlag = 1
End If
On Error GoTo 0
I hope the code above is well enough explanatory..
Do let me know if my blog can be helpful to you:
http://csesupport.blogspot.com
On Jan 24, 11:42 am, satish p <[email protected]> wrote:
> Hi,
> this is satish,pls clarify my doubts in qtp how to captue the errors
> in on error resume next statement pls post answer
>
> Regards,
> satish
--
You received this message because you are subscribed to the Google
"QTP - HP Quick Test Professional - Automated Software Testing"
group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/MercuryQTP?hl=en