Forum Discussion
HKosova
Alumni
14 years agoHi Vinod,
I've got an explanation from developers regarding the issue.
It looks like you're using TestComplete on a computer with .NET Framework 3.5 or 4. In this case, TestComplete uses the .NET WCF API to interact with web services. The issue happens, because your tested web service sends back a SOAP fault message and .NET can't parse this message.
To avoid the issue, you can use TestComplete on a computer that doesn't have .NET Framework 3.5 and 4.0. In this case, TestComplete will use a native web service API that parses SOAP fault messages properly.
If using a computer without the .NET Framework isn't an option, you can do this:
- download and unzip the attached archive containing the Global.aqview file;
- copy this file to the following folders:
C:\Program Files\Automated QA\TestComplete 8\Views\
C:\Users\<username>\AppData\Local\AutomatedQA\TestComplete\8.0\ (if you use Windows 7 or Vista)
C:\Documents and Settings\<username>\Local Settings\Application Data\AutomatedQA\TestComplete\8.0\ (if you use Windows XP)
- launch TestComplete and go to Tools | Options | Engines | Web Services;
- unselect the Use managed code to invoke web service methods option and click OK.
Please note that since SOAP fault is essentially an exception, you'll need to handle it using On Error Resume Next and Err object. For example:
Let me know how it works for you.
I've got an explanation from developers regarding the issue.
It looks like you're using TestComplete on a computer with .NET Framework 3.5 or 4. In this case, TestComplete uses the .NET WCF API to interact with web services. The issue happens, because your tested web service sends back a SOAP fault message and .NET can't parse this message.
To avoid the issue, you can use TestComplete on a computer that doesn't have .NET Framework 3.5 and 4.0. In this case, TestComplete will use a native web service API that parses SOAP fault messages properly.
If using a computer without the .NET Framework isn't an option, you can do this:
- download and unzip the attached archive containing the Global.aqview file;
- copy this file to the following folders:
C:\Program Files\Automated QA\TestComplete 8\Views\
C:\Users\<username>\AppData\Local\AutomatedQA\TestComplete\8.0\ (if you use Windows 7 or Vista)
C:\Documents and Settings\<username>\Local Settings\Application Data\AutomatedQA\TestComplete\8.0\ (if you use Windows XP)
- launch TestComplete and go to Tools | Options | Engines | Web Services;
- unselect the Use managed code to invoke web service methods option and click OK.
Please note that since SOAP fault is essentially an exception, you'll need to handle it using On Error Resume Next and Err object. For example:
On Error Resume Next
Set surfer1 = webservices.TMI_orignal1.getCustomerStatusByCRN(mid1,tmp1,slave,crn,ec)
If Err = 0 Then
MsgBox surfer1.status
Else
Log.Error "The web service has returned an error.", Err.Description
End If
Let me know how it works for you.