HI,
I am trying to click on the button on silverlight application but its throwing an exception. I have used the same method for clicking on other button where it worked. Not sure why it is throwing an exception here.
I am trying to click on the button on silverlight application but its throwing an exception. I have used the same method for clicking on other button where it worked. Not sure why it is throwing an exception here.
public void OpenChartTemplate()
{
ClickChartButton(ControlsDefinition.LoadChartTemplateButton);
}
public void ClickChartButton(string buttonName)
{
try
{
Button button = _app.Find.ByName<
Button
>(buttonName);
button.EnsureClickable();
button.User.Click();
_app.RefreshVisualTrees();
}
catch (TimeoutException exc)
{
Trace.WriteLine("@" + DateTime.Now.ToLongTimeString() + " " + buttonName + " " + exc.ToString());
}
}