Quantcast
Channel: WCF, ASMX and other Web Services
Viewing all articles
Browse latest Browse all 555

Soap web service attribute question

$
0
0

Hi,

I'm new on web service and I'm trying to make web service to pass id and password like below

<ns:POS><!--Zero or more repetitions:--><ns:Source ><!--Optional:--><ns:RequestorID RequestorID="?"  RequestorPassword="?"><!--Optional:--></ns:RequestorID><!--Optional:--></ns:Source></ns:POS>

but what I find is as below

<tem:POS><!--Optional:--><tem:Source><!--Optional:--><tem:RequestorID>?</tem:RequestorID><!--Optional:--><tem:RequestorPassword>?</tem:RequestorPassword></tem:Source><!--Optional:--><tem:RequestorName>?</tem:RequestorName></tem:POS>

here below the code so far 

    public class MyWebService : System.Web.Services.WebService
    {
        public class Source
        {
            public string RequestorID;
            public string RequestorPassword;
        }

        public class POS
        {
            public Source Source;
        }


        public class ReadRQ
        {
            public POS POS;
        }


        [WebMethod]
        public void ReadService(ReadRQ ReadRQ)
        {
        }

    }


Viewing all articles
Browse latest Browse all 555

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>