CRegistry:GetWnd
The GetWnd method returns a window handle from a registry key. If the value does not exist in the registry, nil is returned.
| 
 handle = CRegistry:GetWnd( sName ) 
 
  | 
Note that the handle applies only to a specific window displayed on the Mira desktop. If you close the window for a handle and then create a new window of the same type, it will have a different handle value. Use this method when you want to fetch the handle of an existing window between scripts.
The following script opens a key specified by sKeyName and returns a window handle saved under the name "Window":
| 
 R = CRegistry:Open( sKeyName )  | 
 -- open the key and create a CRegistry object  | 
| 
 h = R:GetWnd( "Window" )  | 
 -- fetch the value of "Window"  | 
| 
 Printf( "Window handle= \'%s\' ", h )  | 
 -- Result: Window handle= nil (the value did not exist)  |