GenericDialog RowDelete = new GenericDialog(ActiveApplication, "Delete", true, "");
RowDelete.ButtonText =
"Cancel";
Manager.Current.DialogMonitor.AddDialog(RowDelete);
Console.WriteLine("Delete dialog text : " + RowDelete.ButtonText);
RowDelete.WaitUntilHandled(5000);
/*****************************************/
I am getting following error,
/*****************************************/
System.TimeoutException: Timed out waiting '5000' msec. for any dialog to be handled '1'
Result StackTrace:
at ArtOfTest.WebAii.Win32.Dialogs.BaseDialog.WaitUntilAnyHandled(IEnumerable`1 dialogs, Int32 handleCount, Int64 timeoutMilliseconds, Boolean resetHandleCount)
at ArtOfTest.WebAii.Win32.Dialogs.BaseDialog.WaitUntilHandled(Int32 handleCount, Int32 timeout, Boolean resetHandleCount)
at
Kindly help me, thanks in advance.
Regards
Chery Jose
Hi
I need to extract the content of textcontrol and other control from code behind and store it for later use for comparing in subsequent test cases. I searched all around but didn't get any solution. for the time being I am using following code to extract the content. txtNewcontent = Pages.WebApp.SilverlightApp.TxtCustomtextbox.Text Similarly I am storing all controls data for comparision. Let me know if there is any better way to do it.// Click 'OverridelinkLink' try{ Pages.CertificateError.OverridelinkLink.Click(false); }catch(FindException e){ Log.WriteLine("IE Override Link not found"); }// Execute test 'Verification' try{ ExecuteTest("C:\\pathhToTest"); }catch(NullReferenceException e){ Log.WriteLine("NullRef"); }catch(TimeoutException t){ Log.WriteLine("Timeout exception...."); }
SubTest
[CodedStep(@"Navigate to vanity url]")]
public void SubTest_CodedStep()
{
// Navigate to : 'http://- DataDriven: [$(Vanity)].com/' - DataDriven: [$(test)]
String vanity = ((string)(System.Convert.ChangeType(Data["Vanity"], typeof(string))));
String fullUrl = "http://" + vanity + ".qasb5.com";
Log.WriteLine("NAVIGATING TO: " + fullUrl);
ActiveBrowser.NavigateTo(fullUrl, false);
}
[CodedStep(@"Verify element 'DealerLogoPanelDiv' 'is' visible.")]
public void Verification_CodedStep()
{
// Verify element 'DealerLogoPanelDiv' 'is' visible.
Log.WriteLine("starting test findDealerLogo");
HtmlFindExpression expr = new HtmlFindExpression("id=~DealerLogoPanel");
ActiveBrowser.WaitForElement(expr, 4000, false);
Element e1 = ActiveBrowser.Find.ByExpression(expr);
HtmlControl ctrl = new HtmlControl(e1);
Assert.IsTrue(ctrl.IsVisible());
}
I hope I provided enough information and would appreciate any help!
Mario