HideWindow()

Syntax

HideWindow(#Window, State [, Flags])
Description
Hides or shows the specified window.

Parameters

#Window The window to use.
State It can be one of the following values:
  #True : the window is hidden.
  #False: the window is shown. The window is automatically activated (gets the focus), 
          unless the #PB_Window_NoActivate flag is set.
Flags It can be a combination of the following values:
  #PB_Window_NoActivate    : the window will be shown but not activated (only valid when un-hiding the window).
  #PB_Window_ScreenCentered: the window will be screen centered (only valid when un-hiding the window).
  #PB_Window_WindowCentered: the window will be window centered (only valid when un-hiding the window).

Return value

None.

Example

  If OpenWindow(0, 200, 200, 220, 100, "HideWindow()", #PB_Window_SystemMenu)
   
   ButtonGadget  (1, 10, 60, 200, 30, "Hide the window")
   
   Repeat
     Event = WaitWindowEvent()
          
     Select Event
     
       Case #PB_Event_Gadget
         Select EventGadget()
           Case 1
             
             HideWindow(0, #True)  
             Debug "Window hidden."
             MessageRequester("Info", "Press OK to show the window")
             HideWindow(0, #False)  
             Debug "Window is visible."
                              
           EndSelect
            
     EndSelect
   Until Event = #PB_Event_CloseWindow
 EndIf

See Also

OpenWindow()

Supported OS

All

<- GetWindowTitle() - Window Index - IsWindow() ->