IGlass GUI for blitzmax - IV

BlitzMax Forums/BlitzMax Programming/IGlass GUI for blitzmax - IV

Hi Gents,

I should be able to set the value of IGL_Value.Value e.g.

Global MyValue:IGL_Value
MyValue=IGL_Value.Create(MyWindow01,"My Value :",150,50,5,50,1,0,100,True)
MyValue.Value=50

It's just that it does not appear to work for the following code:

Type IGL_WorkStep Extends IGL_Window

Field progressBar:IGL_Progress
Field value:IGL_Value
Field maxValue:Int

Function CreateIt:IGL_WorkStep(Caption:String, Px:Int, Py:Int, Tx:Int, Ty:Int)
Local newWorkStep:IGL_WorkStep = New IGL_WorkStep

Local BLock:Byte = False
Local BMinimize:Byte = False
Local BClose:Byte = False

newWorkStep.Setup(Caption, Px, Py, Tx, Ty, BLock, BMinimize, BClose, IGL_NormalWindow)

Return newWorkStep
End Function

Method Setup(Caption:String, Px:Int, Py:Int, Tx:Int, Ty:Int, BLock:Byte, BMinimize:Byte, BClose:Byte, IGL_NormalWindow:Int)

Super.Setup(Caption, Px, Py, Tx, Ty, BLock, BMinimize, BClose, IGL_NormalWindow)

'Add progress bar
progressBar = IGL_Progress.Create(Self, "Qty", 5, 20, 95, 125, 0, 999999)

'Add value
value = IGL_Value.Create(Self,"Qty",30,0,6,0,1.0,-1000.0,1000.0,True)
End Method

Method setQty(qty:Int)
value.Value = qty
progressBar.Value = value.Value' = qty'qty
If qty > maxValue Then
maxValue = qty
progressBar.Maximum = maxValue
value.Maximum = maxValue
EndIf
End Method

End Type

I belive the line value.Value = qty should update the IGL_Value however the component does not update but the progress bar does?