What is my return type for a webservice that uses a database?

J

jm

I have mostly seen simple examples that add two numbers and return an
int or simple hello world string. What I read is that whatever I send
back it will be in JSON if I use [ScriptService], but I don't know
what to send back besides primitive types.

Just wondering how to proceed.

Thank you for any help.
 
A

Alvin Bruney [ASP.NET MVP]

Return type should be XML for XML Web Services. XML can flatten any object
type so you should be able to pass any serializable object. Ofcourse, the
job is yours to unflatten it on the otherside for none primitive types.

--

Regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Download OWC Black Book, 2nd Edition
Exclusively on www.lulu.com/owc $15.00
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top