Ejemplo n.º 1
0
        static void Main(string[] args)
        {
            try
            {
                var binding = new BasicHttpBinding()
                {
                    MaxReceivedMessageSize = 1000000
                };
                var endpoint = new EndpointAddress(ConfigurationManager.AppSettings["ServerEndPoint"]);

                FileStoreService.OperationsClient client = new FileStoreService.OperationsClient(binding, endpoint);

                var result = client.Register(new FileStoreService.RegisterRequestModel()
                {
                    Id      = Guid.NewGuid().ToString(),
                    Name    = "SoapCore Demo",
                    EmailId = "*****@*****.**"
                });
                Console.WriteLine(result.Message);
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex);
            }

            Console.Read();
        }
Ejemplo n.º 2
0
        static void Main(string[] args)
        {
            try
            {
                FileStoreService.OperationsClient client = new FileStoreService.OperationsClient();
                var result = client.Register(new FileStoreService.RegisterRequestModel()
                {
                    Id      = Guid.NewGuid().ToString(),
                    Name    = "WCF Demo",
                    EmailId = "*****@*****.**"
                });
                Console.WriteLine(result.Message);
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex);
            }

            Console.Read();
        }