When a button is clicked with a mouse, ( or even mouse-over ) in W10 GUI client, 11.6.4, it turns light-blue. Normally, then when the button is no longer pressed, it turns back to grey.
Our problem is when we have an Add button, for instance, the user presses the add button to add a record, so we set sensitive = false, so that the add button cannot be pressed while the users is entering data, until the record is saved. Then, we set the add button to sensitive = true again. The Add button remains blue, but it should go back to gray.
Here is a code sample:
DEFINE BUTTON Btn-A LABEL "&A Btn" SIZE 15 BY 1.14.
DEFINE BUTTON Btn-B LABEL "&B Btn" SIZE 15 BY 1.14. DEFINE FRAME DEFAULT-FRAME Btn-B AT ROW 2 COL 10 Btn-A AT ROW 2 COL 30 WITH 1 DOWN. view frame default-frame. Btn-A:SENSITIVE = true.Btn-B:SENSITIVE = true. on choose of Btn-A do: Btn-A:sensitive = false./* pause 2 no-message.*/ Btn-A:SENSITIVE = true. end.
on choose of Btn-b do: end. wait-for close of this-procedure.
Why does setting the sensitive to false and back to true again make the button keep the blue colour ?
How can we prevent this and make the button turn grey again ? ( like button B )
Thanks in advance.
The color blue, is because the change of focus...
on choose of Btn-b
APPLY "ENTRY" TO btn-A.
you'll move the the focus, hence the blue shading.
I hope I got your question right.... did I?
This looks like a bug. If I enable and disable the button by directly calling the Windows function which enables and disables a window the problem doesn't happen. There must be something else which OpenEdge is doing while running the trigger which is causing the problem. Please contact Progress Technical Support to log a bug.
Thanks for your suggestion Octavioolguin.
That would make sense, but it doesn't actually change anything, the button still stays blue.
Thanks Matt. I'll log it as a bug with Tech Support.