Dear Data Access Worldwide Forum Team
Based on extracted code below:
Object oWebMainPanel is a cWebPanel
Set piColumnCount to 10
Object of0yearyear is a cWebForm
Entry_Item f0year.year
Set piColumnSpan to 3
Set piColumnIndex to 0
Set psLabel to "year:"
Set peLabelAlign to alignLeft
Procedure Refresh Integer eMode
Local Integer iRec
Local String sdb
Forward Send Refresh eMode
Get Current_record of (Server(Self)) to iRec
Get Field_Current_Value of (Server(Self)) Field f0year.create_db to sdb
Direct_Output "testing"
Writeln "testing"
Writeln iRec
Writeln sdb
Close_Output
If sdb eq "1" Begin
Direct_Output "testing1"
Writeln "testing1"
Writeln "1"
Close_Output
Set pbEnabled of (oWebButton1(Self)) to False
End
If sdb eq "" Begin
Direct_Output "testing1"
Writeln "testing1"
Writeln "0"
Close_Output
Set pbEnabled of (oWebButton1(Self)) to True
End
End_Procedure
End_Object
Object of0yearcreate_db is a cWebCheckBox
Entry_Item f0year.create_db
Set piColumnSpan to 4
Set piColumnIndex to 0
Set psCaption to "create db"
Set peLabelAlign to alignLeft
End_Object
I would like to perform control "oWebButton1" change from enabled to disabled (or vice versa) based on value variable "sdb".
But it doesn't work. the control oWebButton always set enabled.
I found it because of the last command "Set pbEnabled of (oWebButton1(Self)) to True".
Could you pleased show me how to overcome this trouble?
Thanks you very much. I'm looking to your soon reply.
Your sincerely
Yasa Nataditia