![]() |
[SOLVED] Determine controlbutton click |
Post Reply ![]() |
Author | |
Aaron ![]() Senior Member ![]() Joined: 29 January 2008 Status: Offline Points: 2192 |
![]() ![]() ![]() ![]() ![]() Posted: 17 April 2011 at 10:35am |
Hi,
I'm already using a commandbars PopupMenu in my application and it's working fine. Now I need to determine when a button is down and up. "Up" doesn't seem to be a problem because Execute event is fired when I release the button. But the difficult part (maybe piece of cake
![]() Any advice / solution will be greatly appreciated
Thanks a lot in advance
*edit* ExecuteOnPressInterval for PopupMenu has been added in V15.1.2 (didn't work) but fixed in V15.1.3
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
![]() |
|
jpbro ![]() Senior Member ![]() ![]() Joined: 12 January 2007 Status: Offline Points: 1355 |
![]() ![]() ![]() ![]() ![]() |
I would have hoped that the ExecuteOnPressInterval property would have worked, but unfortunately it doesn't work for CommandBar controls in a popup menu :(
I can't think of a good reason why it shouldn't, so maybe a support ticket is appropriate here? (Edited for wrong property name) |
|
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3 Language: Visual Basic 6.0 SP6 |
|
![]() |
|
jpbro ![]() Senior Member ![]() ![]() Joined: 12 January 2007 Status: Offline Points: 1355 |
![]() ![]() ![]() ![]() ![]() |
This seems to do the trick (not tested to heavily though, so there may be issues I didn't anticipate):
uploads/2676/PopupControlExecuteOnPress.zip |
|
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3 Language: Visual Basic 6.0 SP6 |
|
![]() |
|
jpbro ![]() Senior Member ![]() ![]() Joined: 12 January 2007 Status: Offline Points: 1355 |
![]() ![]() ![]() ![]() ![]() |
And I should say - it would be better still if ExecuteOnPressInterval worked when the controls are shown as part of a popup menu.
|
|
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3 Language: Visual Basic 6.0 SP6 |
|
![]() |
|
Aaron ![]() Senior Member ![]() Joined: 29 January 2008 Status: Offline Points: 2192 |
![]() ![]() ![]() ![]() ![]() |
Hi Jason,
Thanks a lot for looking at my problem
In my current implementation I already have a timer to control some processes (only for some cases I need what I previously asked, only thing I need is execute a process during mousedown) I don't see how Execute event is going to help me (if ExecuteOnPressInterval worked like should...) to determine if user releases mouse button.
I will do some tests and report back inhere. Meanwhile support can also take a look at NOT working ExecuteOnPressInterval property
Thanks again
![]() |
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
![]() |
|
jpbro ![]() Senior Member ![]() ![]() Joined: 12 January 2007 Status: Offline Points: 1355 |
![]() ![]() ![]() ![]() ![]() |
Just to be clear - my example code shows how to process repeatedly only while the mouse is down (like holding down on an updown ctrl button for example to increment/decrement a counter)
Do you just need to know when the mouse is down initially (to start some kind of processing), and when the mouse is up initially (to end that processing)? This should be doable with minor modifications (I think I can make them if this is what you need). |
|
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3 Language: Visual Basic 6.0 SP6 |
|
![]() |
|
Aaron ![]() Senior Member ![]() Joined: 29 January 2008 Status: Offline Points: 2192 |
![]() ![]() ![]() ![]() ![]() |
Hi Jason,
Do you just need to know when the mouse is down initially (to start some kind of processing), and when the mouse is up initially (to end that processing)? This should be doable with minor modifications (I think I can make them if this is what you need).
Yes, that is what I need
![]()
Thanks
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
![]() |
|
jpbro ![]() Senior Member ![]() ![]() Joined: 12 January 2007 Status: Offline Points: 1355 |
![]() ![]() ![]() ![]() ![]() |
If you remove the .CloseSubMenuOnClick property set from my demo, then start the demo:
1) Click the button (the popup appears) 2) Click and hold on the "Test" item, notice the text at the top of the window - the timer code can call your function repeatedly (you can change the timer interval for different processing speeds). 3) Release the mouse - the popup should disappear. Is this what you need? |
|
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3 Language: Visual Basic 6.0 SP6 |
|
![]() |
|
Oleg ![]() Admin Group ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
Thanks, ExecuteOnPressInterval for Popup Menus implemented.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
Aaron ![]() Senior Member ![]() Joined: 29 January 2008 Status: Offline Points: 2192 |
![]() ![]() ![]() ![]() ![]() |
Hi Oleg,
Thanks a lot
![]() Question: After button is pressed (mousebutton is released), does Execute event still fire one time? If it doesn't I dont know when to stop process and this isn't solving my case. I need to know when mousebutton is released (or pressed) and have to check this in Execute event.
Thanks
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
![]() |
|
Oleg ![]() Admin Group ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
If CloseSubMenuOnClick will be TRUE, Execute event will fire and will close popup.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
Aaron ![]() Senior Member ![]() Joined: 29 January 2008 Status: Offline Points: 2192 |
![]() ![]() ![]() ![]() ![]() |
Hi Oleg, I believe this is exactly what I need. Can you give me a date when this will be released? Thanks
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
![]() |
|
Aaron ![]() Senior Member ![]() Joined: 29 January 2008 Status: Offline Points: 2192 |
![]() ![]() ![]() ![]() ![]() |
Hi Oleg,
I tried with V15.1.2
Thanks
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
![]() |
|
Oleg ![]() Admin Group ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
Thanks. Updated.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
Post Reply ![]() |
|
Tweet
|
Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |