Hi,
I've just started learning to create/consume web services using VS2005 and C#. I've written a program that consumes this service:
http://www.webservicex.net/CurrencyConvertor.asmx
Code:
namespace SOAPDemo
{
class MyService
{
static void Main(string[] args)
{
ConvertorService.CurrencyConvertor _Service =
new ConvertorService.CurrencyConvertor();
String s1 = "USD";
String s2 = "QAR";
double rate = _Service.ConversionRate(
SOAPDemo.ConvertorService.Currency.USD,
SOAPDemo.ConvertorService.Currency.QAR);
Console.WriteLine( "The current rate is : " + rate );
Console.ReadKey();
}
}
}
As you can see the remote method "ConversionRate" only accepts parameters of type "ConvertorService.Currency.xxx". But I want to take the parameters as inputs from the user which will be stored in the form of strings. So how can I pass them to the method??
This is my first program and I'm really new to this.
Any sorta help wud be gr8ly appreciated.
________________________
There is no patch for ignorance