R
Rudiga
Hi
I am trying to build in a try-catch block to access a web service and am
trying to control how long it attempts to access to service before running
the catch part of the code. Is there a specific way of doing this?
try
{
// access service
//ans = return answer from service
//run calculations on answer
}
catch (Exception)
{
Console.WriteLine("Error in connecting to service");
}
This code works however takes forever to give up the try part of the code.
Thank you
Rudiga
I am trying to build in a try-catch block to access a web service and am
trying to control how long it attempts to access to service before running
the catch part of the code. Is there a specific way of doing this?
try
{
// access service
//ans = return answer from service
//run calculations on answer
}
catch (Exception)
{
Console.WriteLine("Error in connecting to service");
}
This code works however takes forever to give up the try part of the code.
Thank you
Rudiga