static void Main(string[] args) { InstanceContext objSite = new InstanceContext(new CallbackHandler()); ServiceInfoClient objProxy = new ServiceInfoClient(objSite); Console.WriteLine("Type the path"); string strPath = Console.ReadLine(); objProxy.GetDirectoryInfo(strPath); Console.ReadKey(); }