0

I am runing Watin dll in a C# script that opens and close browser with a long list of url

using (var browser = new IE(url))
{
 //do stuffs
 browser.Close();
}

most of the time it works without erros but sometime Watin throw a 'WatiN.Core.Exceptions.TimeoutException'

It looks that exception canot be catch like classics exception by a classix try catch

try
{
 using (var browser = new IE(url))
  {
   //do stuffs
   browser.Close();         
  }
}

catch (Exception e)
{
//never go in
}

Around 1 time in 100 , watin fails to open link, and instead going in Exception, it stop script and throw me an Exception with boring message : An unhandled exception of type 'WatiN.Core.Exceptions.TimeoutException' occurred in WatiN.Core.dll

Do you know how to catch this Exception or how to prevent it?

Yahya
  • 3,386
  • 3
  • 22
  • 40
lambdaDev
  • 500
  • 4
  • 18

0 Answers0