Page 1 of 1

how to check whether launched windows exists or not in c#

Posted: Sat May 26, 2018 4:36 pm
by learnq
I am very very new to this..

I have launched the window application using runapplication command

But after that how i can ensure whether that app is launched or not in C# code?

Please help..

Re: how to check whether launched windows exists or not in c#

Posted: Mon May 28, 2018 8:21 am
by odklizec
Hi,

The easiest way to check if the application is running is to check the presence of main dialog window (its title or any element inside the app window). I would personally use Validate Exists action. My I ask why you must do such validation in code? You can simply record Validate Exists action and if really needed, convert it to code. But honestly, since you mentioned you are new to Ranorex, you should stick with Record and available pre-defined actions. Only after you gain some skills, you can start to explore code.