Sending and receiving XML data

I am a .NET begginer, and I am trying to develop web services using C #, so I can send XML data to a specific URL. I cannot use the web link and I need to build the xml data using this format:

<?xml version="1.0" encoding="UTF-8"?>
<soap-env:Envelope xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/">
 <soap-env:Body>
 <m:Send xmlns:m="http://www.urltest.com/soap/arquivo.xsd">
 <user id="522" senha="pwd000"/>
 <ack txt_email="teste@email.com" num_ack="12345678910" num_obs="1"/>
 </m:Send>
 </soap-env:Body>
</soap-env:Envelope>

I am trying to research MessageContracts, but so far it has not helped me.

Thanks in advance,

Felipe

+3
source share
3 answers

The best (fastest, easiest) way to develop a web service is to use WCF. Have you ever looked at him?

+1
source

This has nothing to do with xml. just send the string. using WebRequest, TcpClient, Socket or something else.

0
0

Source: https://habr.com/ru/post/1720456/


All Articles