sindhu10
7 years agoContributor
How to check WinformsObject Exists or not
Hi,
i am trying to check WinformsObject exists or not but the below code is not working
if(Sys.Process.WaitWinFormsObject("DisplayScheduleMessage").Exists)
{
Sys.Process.WinFormsObject("DisplayScheduleMessage").Close();
}
else
{
Log.Message("Window doesnt exists continue next step");
}
Please advise.
Thanks,
Thanks!
i tried the below code and its working.
var w = Sys.Process().WaitWinFormsObject("DisplayScheduleMessage", 1000);
if(w.Exists && w.VisibleOnScreen)
{
}
else
{
}