Documentation component by D.Glodt (c)2000-2001 | Appendix A: QProgress |
|
Field | Type | R/W | Défault | |
|
|
|
|
|
Handle | INTEGER | RW | ||
Height | INTEGER | RW | ||
Left | INTEGER | RW | 0 | |
Parent | Handle QFORM/QPANEL/QTABCONTROL | RW | ||
Top | INTEGER | RW | 0 | |
Width | INTEGER | RW | ||
Visible | INTEGER | RW | True | |
Value | INTEGER | RW | ||
Progress value. |
Method | Type | Description | Params | |
|
|
|
|
|
Event | Type | Occurs when... | Params | |
|
|
|
|
|
$TYPECHECK ON
$Include "Rapidq.inc"
$include "Object\QProgress.inc"
Declare Sub Start
Declare Sub Display
dim pourcent as integer
dim tempo as QTIMER
tempo.interval=100
tempo.enabled=False
tempo.OnTimer=Display
dim Bar as QProgress
CREATE Form AS QFORM
Caption = "Progress Bar"
Width = 350
Height = 180
Center
CREATE Button1 AS QBUTTON
Caption = "Start"
Left = 125
Top = 100
OnClick=Start
END CREATE
END CREATE
Bar.parent=form.handle
Bar.left=10
Bar.Top=40
Bar.Width=305
Bar.Height=25
Form.ShowModal
Sub Display
if pourcent<100 then
pourcent=pourcent+1
Bar.Value=pourcent
else
tempo.enabled=False
end if
End Sub
Sub Start
pourcent=0
Bar.Value=0
tempo.enabled=True
End Sub