Special Webservice Call

Code um einen Webservice manuell anzusprechen.

using System;
  using System.Net;
  using System.Web.Services.Protocols;


namespace ConsoleApplication1
{
    internal class Program
    {
        private static void Main(string[] args)
        {
            DlgExport_BezugInterfaceHttpService dlg = new DlgExport_BezugInterfaceHttpService();


            WebProxy webProxy = new WebProxy();
            webProxy.BypassArrayList.Add("datenlogistik.test.oiz.ch");
            dlg.Proxy = webProxy;


            string[] egids = new string[1];
            egids[0] = "15647";


            getGebaeudeAllByEgid b = new getGebaeudeAllByEgid();
            b.Egids = egids;


            try
            {
                getGebaeudeAllByEgidResponse response = dlg.getGebaeudeAllByEgid(b);
            }
            catch (SoapException ex)
            {
                throw  ex;
            }
        }
    }
}
Kommentare sind geschlossen

Tags