LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Mouse wheel for scrolling in subpanel

Solved!
Go to solution

Can anyone tell me if there is a way to use the mouse wheel to scroll vertically in a subpanel window in 7.1? (I have the vertical scroll bar enable, and I have key focus set to true.)   I read that this is suppose to work for listboxes, is it suppose to apply to subpanels as well?

 

Thanks!

 

Greg

Message Edited by gstanczak on 09-28-2009 03:16 PM
v7.1
0 Kudos
Message 1 of 3
(3,133 Views)
Solution
Accepted by topic author gstanczak

No way without writing code as far as I know. When I wanted to do something like this in LabVIEW 7.0, I had a loop which polled the wheel using the input VIs, and used that to generate a user event whenever there was a scroll. I then used that to set the FP.Origin property in the subVI to simulate a scroll. Note that you have to remove the subVI from the panel first, because you can't write the origin property to a VI in a SP.

 

So the order was -

  1. defer updates in the caller (so the user doesn't see the VI being removed).
  2. remove SP.
  3. set origin (and make sure the user doesn't scroll past the end of the allowed area).
  4. insert VI into SP.
  5. undefer updates.

___________________
Try to take over the world!
Message 2 of 3
(3,102 Views)

Great!  I will give that a try.

 

Regards,

Greg

v7.1
0 Kudos
Message 3 of 3
(3,075 Views)