473,387 Members | 1,532 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Overloading Web Service Calls

Hello,
For a long time we've been told that you can't overload web service
calls but recently we found a way to do it using the WebMethod
attribute as in the example below. This will allow us as you can see
to have two web service methods of the same name and will show them as
such in intellisense.

I am wondering if there is any concern in doing this? Is there any
documentation anywhere that explains what might be happening with SOAP
that could make doing this a bad idea? Generally just looking for any
information at all that could guide us in whether or not we should be
doing this on a regular basis.
[WebMethod(MessageName="GetUsersForRuleAndOneSubLev el")]
public DataSet GetUsersForRule(string szRule, string szLevel1, string
szUserId)

[WebMethod(MessageName="GetUsersForRuleAndTwoSubLev els")]
public DataSet GetUsersForRule(string szRule, string szLevel1, string
szLevel2,
string szUserId, string szBusinessUnit)
Jul 21 '05 #1
2 3361
From what I recall of reading through the WS specification its fully
supported. As such you should probably have no issues with it.

--
Regards

John Timney
Microsoft Regional Director
Microsoft MVP
"Doug" <dn******@dtgnet.com> wrote in message
news:ff**************************@posting.google.c om...
Hello,
For a long time we've been told that you can't overload web service
calls but recently we found a way to do it using the WebMethod
attribute as in the example below. This will allow us as you can see
to have two web service methods of the same name and will show them as
such in intellisense.

I am wondering if there is any concern in doing this? Is there any
documentation anywhere that explains what might be happening with SOAP
that could make doing this a bad idea? Generally just looking for any
information at all that could guide us in whether or not we should be
doing this on a regular basis.
[WebMethod(MessageName="GetUsersForRuleAndOneSubLev el")]
public DataSet GetUsersForRule(string szRule, string szLevel1, string
szUserId)

[WebMethod(MessageName="GetUsersForRuleAndTwoSubLev els")]
public DataSet GetUsersForRule(string szRule, string szLevel1, string
szLevel2,
string szUserId, string szBusinessUnit)

Jul 21 '05 #2
On 21 Sep 2004 05:28:35 -0700, dn******@dtgnet.com (Doug) wrote:
For a long time we've been told that you can't overload web service
calls but recently we found a way to do it using the WebMethod
attribute as in the example below. This will allow us as you can see
to have two web service methods of the same name and will show them as
such in intellisense.


If it's an issue for you, test also using the Microsoft Office Web
Services Toolkit as a client to your interface with the overloaded
webservice method names.

I remember last year we had some problem with this toolkit (ie with
the VBA glue code its wizard generates) and overloaded web service
methods, and we changed to unique method/webservice names to avoid it.

I can't remember the specifics now, but I know we ended up deciding it
was easier for us and our customers (who use that Toolkit with Excel
to build custom frontends and reports against our application) if we
changed to non-overloaded method names.
ted.h.
--
Ted Harper (Sydney, Australia)
Jul 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

17
by: Terje Slettebų | last post by:
To round off my trilogy of "why"'s about PHP... :) If this subject have been discussed before, I'd appreciate a pointer to it. I again haven't found it in a search of the PHP groups. The PHP...
30
by: | last post by:
I have not posted to comp.lang.c++ (or comp.lang.c++.moderated) before. In general when I have a C++ question I look for answers in "The C++ Programming Language, Third Edition" by Stroustrup....
5
by: | last post by:
Hi all, I've been using C++ for quite a while now and I've come to the point where I need to overload new and delete inorder to track memory and probably some profiling stuff too. I know that...
18
by: uday | last post by:
Does C supports overloading. I am thinking no. But some people are saying yes. If yes how. Please answer with examples. Also in c++ size of empty class is one. why. and what are the default...
31
by: | last post by:
Hi, Why can I not overload on just the return type? Say for example. public int blah(int x) { }
2
by: Doug | last post by:
Hello, For a long time we've been told that you can't overload web service calls but recently we found a way to do it using the WebMethod attribute as in the example below. This will allow us as...
4
by: Doug | last post by:
Hi I am 'returning' to the learning of C# after a change in jobs and I remember that I used to struggle with the defintion, purpose and function of 'overloading'. When I was beginning with C# I...
11
by: placid | last post by:
Hi all, Is it possible to be able to do the following in Python? class Test: def __init__(self): pass def puts(self, str): print str
8
by: Wayne Shu | last post by:
Hi everyone, I am reading B.S. 's TC++PL (special edition). When I read chapter 11 Operator Overloading, I have two questions. 1. In subsection 11.2.2 paragraph 1, B.S. wrote "In particular,...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.