CRegistry:SetWnd
The SetWnd method saves the handle to a GUI window to a Registry key. The handle of the window is obtained using the GetWnd of a class object such as a CPlotView.
| 
 CRegistry:SetWnd( sName, handle ) 
 
  | 
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 saves a string value to the Registry under the name "MyVal":
| 
 R = CRegistry:Open( sKeyName )  | 
 -- open the key and create a CRegistry object  | 
| 
 R:SetWnd( "Window", Wnd )  | 
 -- saves the value Wnd "Window"  |