StatusBarProgressMeter

Manipulates Rhino's status bar progress meter.

Syntax

Start, or show, the progress meter.

rhinoscriptsyntax.StatusBarProgressMeterShow(label, lower, upper, embed_label, show_percent=True)

Set the current position of the progress meter.

rhinoscriptsyntax.StatusBarProgressMeterUpdate(position, absolute=True)

End, or hide, the progress meter.

rhinoscriptsyntax.StatusBarProgressMeterHide()

Parameters

label

Required.  String.  A short description of the progress. (e.g. "Calculating", "Meshing", etc.)

lower

Required.  Number.  The lower limit of the progress meter's range.

upper

Required.  Number.  The upper limit of the progress meter's range.

embed_label

Optional.  Boolean.  If True (Default), then the label will be embedded in the progress meter. If False, then the label will appear to the left of the progress meter.

show_percent

Optional.  Boolean.  If True (Default), then the percent complete will appear in the progress meter.

position

Required.  Number.  The new position of the progress meter.

absolute

Optional.  Number.  If True (Default), then the progress meter is moved to position (absolute). If False, then the progress meter is moved position from the current position (relative).

Returns

Boolean

If starting, or showing, the progress bar, the True or False indicating success or failure.

Number

If setting the position of the progress bar, then the previous position if successful.

None

If ending, or closing, the progress meter, or on error.

Example

import rhinoscriptsyntax as rs

def TestStatusBarProgressMeter():

    lower = 0

    upper = 100

    rs.StatusBarProgressMeterShow("Solving", lower, upper)

    for i in range(lower, upper):

        print i

        rs.StatusBarProgressMeterUpdate(i)

        rs.Sleep(300)

    rs.StatusBarProgressMeterHide()

TestStatusBarProgressMeter()

Also See

Print

MessageBox