home *** CD-ROM | disk | FTP | other *** search
/ io Programmo 40 / IOPROG_40.ISO / SOFT / NETFrameworkSDK.exe / comsdk.cab / samples.exe / Remoting / MyHello / SimpleHelloGetObject2.cs < prev    next >
Encoding:
Text File  |  2000-06-23  |  534 b   |  17 lines

  1. using System;
  2. using System.Runtime.Remoting;
  3. using System.Runtime.Remoting.Channels.HTTP;
  4. using HelloService;
  5.  
  6. public class SimpleHello
  7. {
  8.     public static void Main(String[] args)
  9.     {
  10.         String name = "Bill";    
  11.         ChannelServices.RegisterChannel(new HTTPChannel());
  12.         Hello hello = (Hello)Activator.GetObject(typeof(Hello), "http://localhost:80/HelloService/Hello.soap");
  13.         String result = hello.HelloMethod(name);
  14.         Console.WriteLine("Hello.HelloMethod returned: " + result);
  15.     }
  16. }
  17.