ProgressBarMobile()

Syntax

Result = ProgressBarMobile(#Mobile [, Flags])
Description
Create a new mobile progressbar in the current container.

Parameters

#Mobile A number to identify the new mobile object. #PB_Any can be used to auto-generate this number.
Flags (optional) It can be a combination (using the bitwise OR operator '|') of the following constants:
  #PB_Mobile_Circular     : Use a circular look instead of a line look.
  #PB_Mobile_Indeterminate: The progressbar is infinite and doesn't have a custom value. It's useful when the remaining time is unknown.
If the current container is a 3 slots container, the following constants can be used to select in which slot the progressbar should be created:
  #PB_Mobile_Left  : The progressbar will be set in the left slot.
  #PB_Mobile_Center: The progressbar will be set in the center slot.
  #PB_Mobile_Right : The progressbar will be set in the right slot.

Return value

Returns nonzero on success and zero on failure. If #PB_Any was used as the #Mobile parameter then the return-value is the auto-generated number on success.

Remarks

The following functions can be used to act on the progressbar:

- SetMobileState(): Changes the current value of the progressbar (between 0 and 100).
- GetMobileState(): Returns the current value of the progressbar (between 0 and 100).

The following events are supported with EventType():
  - #PB_EventType_Change: the progressbar value has been changed.

Example

  If ContainerMobile(#PB_Any, #PB_Mobile_Page)
    ProgressBarMobile(1, #PB_Mobile_Circular | #PB_Mobile_Indeterminate)
    HtmlMobile("<br>")
    ProgressBarMobile(0)
    SetMobileState(0, 70) ; Set the progress to 70%
    
    CloseMobileContainer()
  EndIf

See Also

SetMobileState(), GetMobileState()

Supported OS

All

<- OptionMobile() - Mobile Index - SetMobileAttribute() ->