P
P
Pan Propan2015-09-21 14:12:59
SOAP
Pan Propan, 2015-09-21 14:12:59

How to output data from WSDL to DataDridView?

In 1s, I wrote a simple web service that gives the rest of the nomenclature.
I want to write a simple c# application that will display this data.
The request that I send to the service looks like this:
8629ae9e26d348ae91fa01d8d06481ad.png

<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:dag="http://dagfarm.ru/">
   <soap:Header/>
   <soap:Body>
      <dag:PoluchitOstatki/>
   </soap:Body>
</soap:Envelope>

The answer comes like this,
soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope">
   <soap:Header/>
   <soap:Body>
      <m:PoluchitOstatkiResponse xmlns:m="http://dagfarm.ru/">
         <m:return xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <m:StrokaZakaza>
               <m:Nomenklatura>САНИТЕЛЬ гель для рук антисептич. без отдушки с вит. Е 250мл</m:Nomenklatura>
               <m:Proizvoditel>Россия</m:Proizvoditel>
               <m:Cena>228.29</m:Cena>
               <m:Srok>2017-05-01</m:Srok>
               <m:Ostatok>0</m:Ostatok>
            </m:StrokaZakaza>
  d          <m:StrokaZakaza>
               <m:Nomenklatura>САНИТЕЛЬ гель для рук антисептич. без отдушки с вит. Е 250мл</m:Nomenklatura>
               <m:Proizvoditel>Россия</m:Proizvoditel>
               <m:Cena>228.29</m:Cena>
               <m:Srok>2017-05-01</m:Srok>
               <m:Ostatok>0</m:Ostatok>
            </m:StrokaZakaza>
            <m:StrokaZakaza>

I installed the DataGridView widget, my service specified the source.
Now it remains how to properly display data on the widget.
1)How to perform the operation? to hang up the button and to start on it?
2) Do you need to specify cells in the widget in advance? Or are they dynamically formed?
3) Do I need to create a class with a description of data types. And unload data from WSDL into it?
c5c5ccf92cea483fb3e7992fecd6cf0c.png

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Dmitry Kovalsky, 2015-09-21
@mgis

For good, you need to create a ServiceReference in the project, and it will blind you classes based on wsdl.

P
Pan Propan, 2015-09-21
@mgis

Dmitry Kovalsky : brought the data to the form.
Now, as I understand it, you need to call a procedure on the Web service on an event.
but how to do that?
I added the button. And what event to cause?? At the bottom, the arrow indicated some procedures related to the web service? Is this what you need?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question