How to: Consuming webservice in console application (C#)

Feb 11 2011 5:42 PM
Hi,
I'm novice by complete to webservices et al.
I've created successfully a webservice and referenced it
in a console application. By simplification let assume that
the webservice contains a webmethod, the 'classic'
CelsiusToFarenheit (string Celsius).
Once referenced i can see my new namespace
ServiceReference1 with the following classes inside:

CelsiusToFahrenheitRequest
CelsiusToFahrenheitRequestBody (it contains the property Celsius)
CelsiusToFahrenheitResponse
CelsiusToFahrenheitResponseBody (it contains the property CelsiusToFahrenheitResult)
Service1SoapClient (with 5 overloads at the instantiation).

and 2 interfaces:
IService1Soap
IService1SoapChannel

I've intantiated the first 4 classes and toying with it to no avail.
How can i obtain :

string Fahreheit =  ......

Thanks






Answers (2)