M
Mark
I have built Web service that allows me to send input
parameters as a complex type:
public class User
{
public string FirstName;
public string LastName
}
[WebMethod]
public void UpdateUserDetails(User user)
{string fn = user.FirstName; string ln =
user.LastName}
This works fine, assuming I am only sending through a
single update request for User:
<ns0:UpdateUserDetails xmlns="http://MyCompany">
<FirstName>John</FirstName>
<LastName>Doe</LastName>
</ns0
ataFile>
What I would like is be able to update multiple Users
with a single XML document:
<ns0:UpdateUserDetails xmlns="http://MyCompany">
<User xmlns="">
<FirstName>John</FirstName>
<LastName>Doe</LastName>
</User>
<User xmlns="">
<FirstName>Jane</FirstName>
<LastName>Doe</LastName>
</User>
</ns0:UpdateUserDetails>
How should I build a collection class for to contain
multiple instances of User and call this from my Method?
Thanks
Mark
parameters as a complex type:
public class User
{
public string FirstName;
public string LastName
}
[WebMethod]
public void UpdateUserDetails(User user)
{string fn = user.FirstName; string ln =
user.LastName}
This works fine, assuming I am only sending through a
single update request for User:
<ns0:UpdateUserDetails xmlns="http://MyCompany">
<FirstName>John</FirstName>
<LastName>Doe</LastName>
</ns0
![Big Grin :D :D](/styles/default/custom/smilies/grin.gif)
What I would like is be able to update multiple Users
with a single XML document:
<ns0:UpdateUserDetails xmlns="http://MyCompany">
<User xmlns="">
<FirstName>John</FirstName>
<LastName>Doe</LastName>
</User>
<User xmlns="">
<FirstName>Jane</FirstName>
<LastName>Doe</LastName>
</User>
</ns0:UpdateUserDetails>
How should I build a collection class for to contain
multiple instances of User and call this from my Method?
Thanks
Mark