KB-29019: Displaying the progress of a script’s execution on screen.

Question:

How can I create an indicator of the progress of a script’s execution on screen?

Solution:

To do so, you can create an Internal Tag and increment it on the script. Then, add a Rectangle to the screen and create an analog link with the Internal Tag in HorizontalPercentFill property, whose value on the source must be from 0 to the counting’s maximum limit, and the value on the property must be from 0 to 100.

Example:

Set cont = Application.Item(“ContViewer”)
For i=0 to 1000
cont.Value = i
Frame.Refresh True
Next

Note: The Refresh method allows forcing a redrawn of a Screen’s or Splitter’s content. It must be used in Viewer scripts with massive processing (loops, for example) or in method calls demanding a long time and also demanding a visual indication for the progress of a process to users.

Print Friendly, PDF & Email

Este artigo foi útil? Was this helpful?

Classificação média - Average rating 0 / 5. Count: 0

Deixe seu Comentário

Seu endereço de e-mail não será publicado. Campos marcados com asterisco são obrigatórios *