I have a window with lots of edit fields, labels and radio buttons, and a Cancel and Save button.
When I hit the enabled Cancel pushbutton, it is not triggering (should just close the window). The Window close red dot however works.
If I move the window a bit on the screen, and then hit Cancel, it triggers!
Anyone has seen this behaviour, where is the bug?
Please provide more information - Xojo version, target OS, code in button Action handler, does a breakpoint in the handler fire…
1 Like
A sample project would be best. No, we don’t want your big project. Re-create the issue in a small issue-only project.
It’s an exercise in debugging as well. You may discover the cause during the process. However, I tend to find that if you cannot recreate the issue, the problem is your code.
Hi Julia & Tim
Not necessary, I found it by playing around: I had in the pushbutton the ‘Cancel’ slider on. Figured, since I cancel the input of the user it makes senes. But with turning that off it behaved like I want, as a normal push button, like the ‘Save’ button.
This behaviour of buttons I wasn’t aware of…
The Cancel property shouldn’t do anything more than allow the user to activate the button with the Escape key. I haven’t ever seen that prevent mouse actions.
6 Likes
Indeed strange. Thanks anyway.
You’re correct, but I think I too have seen some odd behavior with that property set.
1 Like
Amendment: It is still happening, even with the cancel property off..
It’s strange: sometimes it works, sometimes after hitting af few times, sometimes never.
I circumvented this problem by checking additionally mousedown over that button, the trigger what it is supposed to do in case the button does not fire…
You really need to show us a sample project where this is happening so we can look at other details that could be relevant.
1 Like