Hi all. I have a request for advice on how to handle a situation.
We have a PowerBuilder app of some complexity. For some reason, some of our users are in the habit of double clicking, rather than single clicking (AKA clicking) on a particular commandbutton on a particular response window. I don't know why, and we can't seem to get them to stop doing this.
Unfortunately, what ends up happening is that the (single) click handler runs, and the second click gets queued up to be handled after the click event finishes. Or that's how it seems to me. One possible outcome of the click handler is to make the entire response window close. Thus, when the event finishes, the button that used to be under the cursor is no longer there, and if the user is unlucky, the cursor is over a different commandbutton on a different window. The handler of that commandbutton's click event runs, much to the surprise of the user.
Aside from training, can anyone think of a way of handling this situation? Ideas we have come up with so far are:
- Employ a "are you sure" type message box on the first commandbutton.
- Move the controls around on the second window so that there is nothing in the space where the cursor would be.
We also tried adding a Sleep() before exiting the first click handler, but it seems like the second click event just stays queued up during the entire click handler, Sleep() and all.
Something like:
if AncestorReturnValue = 1 then
return
end if
Not a lot of code, but still might be a lot of work if you have a lot of buttons. For a datawindow button, it would be more complicated.
To be honest, I believe in user education and don't think all of this is worth the trouble.
regards