Is overloading possible in web services?

Answer Posted / neha

Yes it is possible but you have to give different alias name to the web method so that ambiguity can be avoided

---method will be call from application by the name AddInt
[WebMethod Name ="AddInt"]
public void Add(){}//implement code for adding 2 int variable

---------In this step even if you dont give name attribute it will work and method will be called by name Add.
[WebMethod Name ="AddFloat"]
public void Add(){}//implement code for adding 2 float variable

else it will give error

Is This Answer Correct ?    5 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain parts of assembly?

730


What is a reflection?

747


How can we inherit a static member?

783


What do you understand from custom control?

803


What does aspcompat="true" mean?

752


What is difference between singleton and single call?

821


Do gac'ed assemblies have fulltrust?

846


Is post back property in asp net?

733


Where is cookie used in asp.net?

769


How does windows service lifecycle differ from a .standard. Exe?

712


Will the asp.net validators run in server side or client side?

863


What are asp.net web forms?

739


What are cao and sao.

730


Differentiate between globalization and localization.

742


What is event in asp.net?

729