Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Fri Oct 18, 2019 3:50 pm
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 6 posts ] 
Author Message
 Post subject: pushbutton not firing on mouseclick
PostPosted: Thu Nov 03, 2011 9:33 am 
Offline

Joined: Mon Sep 25, 2006 3:25 pm
Posts: 380
I have a pushbutton whose action event doesn't fire when I click it with a mouse.
What its function is is to copy the text from a listbox's active cell on the same window into a separate window.
I know the code works. I have a menuitem that will push the button, and the window pops up.
I've tried putting return true into the mousedown event with no effect.
It also works on Mac with no problem.
Suggestions?


Top
 Profile  
Reply with quote  
 Post subject: Re: pushbutton not firing on mouseclick
PostPosted: Thu Nov 03, 2011 9:56 am 
Offline
User avatar

Joined: Fri Nov 10, 2006 4:10 pm
Posts: 1855
Location: Michigan, USA
If you return true in the MouseDown event it will not fire the Action event, as you're notifying the control not to handle the mouse click. Otherwise it's a Push Button and the Action event isn't firing?

_________________
Windows 8 x64
Windows XP Pro SP3
Ubuntu 11.04 via Virtual Box
RS Enterprise 2012r1.1

Programming Tutorials & Free Projects: http://www.JasonTheAdams.com
"Christianity has not been tried and found wanting; it has been found difficult and not tried." - G.K. Chesterton


Top
 Profile  
Reply with quote  
 Post subject: Re: pushbutton not firing on mouseclick
PostPosted: Thu Nov 03, 2011 10:34 am 
Offline

Joined: Mon Sep 25, 2006 3:25 pm
Posts: 380
Thanks. Now it works on the 2nd click.


Top
 Profile  
Reply with quote  
 Post subject: Re: pushbutton not firing on mouseclick
PostPosted: Thu Nov 03, 2011 10:44 am 
Offline

Joined: Mon Sep 25, 2006 3:25 pm
Posts: 380
Just in it wasn't clear, it should open on the first click.


Top
 Profile  
Reply with quote  
 Post subject: Re: pushbutton not firing on mouseclick
PostPosted: Thu Nov 03, 2011 12:07 pm 
Offline

Joined: Fri Jan 06, 2006 3:21 pm
Posts: 12388
Location: Portland, OR USA
Art wrote:
Thanks. Now it works on the 2nd click.

It's likely that the action event is firing on the first click, but the environment isn't what you expect it to be, so you're not getting the result you expect. Have you put a breakpoint in the action event to check it?


Top
 Profile  
Reply with quote  
 Post subject: Re: pushbutton not firing on mouseclick
PostPosted: Thu Nov 03, 2011 1:43 pm 
Offline

Joined: Mon Sep 25, 2006 3:25 pm
Posts: 380
I guess that wasn't obvious by my post. Yes. Definitely a breakpoint at the start


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group