StatusBarProgress()

Syntax

StatusBarProgress(#StatusBar, Field, Value [, Appearance [, Min, Max]])
Description
Display a progress bar in the specified 'Field' in the given '#StatusBar'.

Parameters

#StatusBar The status bar to use.
Field The field index to set the progress bar. The first field index starts from zero.
Value This specifies the current progress (relative to the current minimum and maximum). To update this value simply call this command again with a different value.
Appearance (optional) It can be used to alter the look of the field with the following values:
  #PB_StatusBar_Raised    : raised borders (has no effect on OS X)
  #PB_StatusBar_BorderLess: without border 
Min, Max (optional) Specifies the boundaries of the progress bar. If they are not specified or have the value #PB_Ignore then current boundaries will be used. The default 'Min' and 'Max' values for newly created status bar fields are 0 and 100.

Return value

None.

Example

  If OpenWindow(0, 0, 0, 340, 50, "StatusBarProgress", #PB_Window_SystemMenu | #PB_Window_ScreenCentered | #PB_Window_SizeGadget)
    If CreateStatusBar(0, WindowID(0))
      AddStatusBarField(120)
      AddStatusBarField(170)
    EndIf

    StatusBarText(0, 0, "ProgressBar !")
    StatusBarProgress(0, 1, 25)
    
    Repeat
    Until WaitWindowEvent() = #PB_Event_CloseWindow
  EndIf

Supported OS

All

<- StatusBarImage() - StatusBar Index - StatusBarText() ->