65.9K
CodeProject is changing. Read more.
Home

How to overload a web method in ASP.NET webservice...?

starIcon
emptyStarIcon
starIcon
emptyStarIconemptyStarIconemptyStarIcon

1.50/5 (4 votes)

Aug 25, 2011

CPOL
viewsIcon

38866

How to overload a web method in ASP.NET webservice...?

Here is the solution to overload a web method in web service... First of all, make changes in this:
 [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
You need to write like this:
[WebServiceBinding(ConformsTo = WsiProfiles.None)]
Then make changes in webmethod. Add messageName property to your webmethod:
[WebMethod (MessageName="YourMessageName")]
After doing this, your webmethod will now be overloaded and no error will arise. Enjoy...