Phantom Documentation

[Help Home] [Phantom Home]
WaitForWindow

bool WaitForWindow(window,int)

Return Type: bool
Parameters: window Win, int iTime

Description:
Waits for a window (Win) to appear for iTime seconds. If the window is found in that time, continues the script and returns 'true'. The function returns true if the window is found in the specified time, false otherwise.

Example Code
use "Notepad.dec";
System("c:\\windows\\system32\\notepad.exe");
bool b = WaitForWindow(Notepad, 10)
if(b){
  Notepad.Close();
}else{
  exception e;
  e.SetError("Notepad not found
!");
  e.throw();

}



 


Copyright 2000-2011 Phantom Automated Solutions