Skip to Content
author's profile photo Former Member
Former Member

overload methods error in web services

Hi Experts,

We want to invoke a DotNet web service. The dotnet web service contains overload methods. When I try to invoke this web service from WSNavigator, it shows "WSDL Operation with name search is overloaded (defined twice). Operation overloading is not supported by proxy generator" error. How to solve this issue?

Best Regards

Tom

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Feb 27, 2009 at 02:32 PM

    Hi Tom,

    TO use overloaded methods u have to specify Message Name property.Find the example.

    Here method say() is overloaded

    [webMethod]

    public string say()

    {

    return "hello";

    }

    [web Method]

    public string say(string p_Name)

    {

    return "Hello " + p_Name + "!";

    }

    Adding the Message name property.

    [WebMethod]public string say()

    {

    return "hello";

    }

    [WebMethod (MessageName="WithOneString")]

    public string say(string p_Name)

    {

    return "Hello" + p_Name + "!";

    }

    Regards,

    Sri.

    Edited by: Srikanth Thatipally on Feb 27, 2009 3:33 PM

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.