Click here to Skip to main content
15,886,362 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi All.
I got a problem here. How to invoke a webservice with complex or non-primitive parameters in ASP.NET/VB.Net.
I have created a webservice but I can't seem to invoke the methods simply bcoz the codes are complex or are of non-primitive parameters. The following message appears:

The test form is only available for methods with primitive types as parameters.

How do I go about it?
Many thanks.

This is the complex code.

<WebMethod()> _
        Public Function WatchListWS(ByVal strName As String) As WatchListIntResp
        Dim watchStatus As String = ""
        Dim resp As New WatchListIntResp
        Dim objWatchList As Object = Server.CreateObject("VREMIT.Enterprise.ComWatchList")

        Try
            watchStatus = objWatchList.mtdMatchExact(strName, g_global_region_code)

            If watchStatus <> "" Then
                resp.watchlistIntCode = "3"
                resp.watchlistIntMsg = "Hit International"
                'strResult = "3 | Hit International "
            Else
                'strResult = " 0 | Not Watched "
                resp.watchlistIntCode = "0"
                resp.watchlistIntMsg = "Not Watched"
            End If
            Return resp

        Catch ex As Exception
            Return Nothing
        End Try
    End Function
Posted
Updated 10-Mar-13 21:54pm
v2
Comments
bbirajdar 10-Mar-13 12:55pm    
Show us the code...

1 solution

If you want to test your web service then grab SOAPUI. A very good tool, though written in Java and hence will require JDK on your machine.

Regards,
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900