Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / September 2005

Tip: Looking for answers? Try searching our database.

Exposing a webservice (Biztalk)

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
doron - 01 Sep 2005 09:25 GMT
Hi all,

I'm exposing an orchestration as a web service which simply replies
the same object it receives by calling an internal ws I wrote which
does the same thing. (getting the object and returning it)

While I was using a simple string the circle worked fine, but after I
switched the object from string to my own type, which is defined in the

original ws, something went wrong.

I have a single function called update which looks like:

public Contact update(Contact contact)
{
   return contact;

}

for some reason when I'm trying to use the exposed ws in one of my
projects the method looks like:

void update(ref contact)

why is that?

Thank you,

Doron.
Pablo Cibraro - 01 Sep 2005 15:17 GMT
Hi doron,
That happens because  your method signature and "void update(ref contact)"
are equivalent in this case. Why are you returning the same object you
received ?.
All objects in .NET are passed by reference to a method, so, you don't need
to return it.
If you want to change some data on the customer object, the following method
signature should be fine:

public void update(Contact contact)
{
 // Change some data on contact
}

Regards,
Pablo Cibraro
www.lagash.com

> Hi all,
>
[quoted text clipped - 25 lines]
>
> Doron.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.