Code: Select all
RepoItemInfo myCoolWindow = GetTheFirstActiveWindow();
if (myCoolWindow is MyProgramRepo.Instance.CoolWindow.SelfInfo)
{
// do stuff
}
else if (myCoolWindow is MyProgramRepo.Instance.FunWndow.SelfInfo)
{
// do other stuff
}
Code: Select all
RepoItemInfo myCoolWindow = GetTheFirstActiveWindow();
if (myCoolWindow is MyProgramRepo.Instance.CoolWindow.SelfInfo)
{
// do stuff
}
else if (myCoolWindow is MyProgramRepo.Instance.FunWndow.SelfInfo)
{
// do other stuff
}
Code: Select all
/dom[@domain='www.ranorex.com' or @domain='www.google.com'][2]
Code: Select all
/dom[@domain='www.ranorex.com' or @domain='www.google.com'][-1]
Code: Select all
string winTitle = formRun.Self.GetAttributeValue<string>("title");
if (winTitle == "Run")
Report.Info("Window 1!");
else if (winTitle == "Run_2")
Report.Info("Window 2!");