LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

picture control mouse property

Solved!
Go to solution

In LV 8.5 I notice that if you reinitialize your picture control to default value (using pop-up menu) the mouse position property no longer works, it will always return 0,0 no matter where the mouse is in the control.  You must destroy and re-create your picture control to fix it at that point.

 

Maybe this has been fixed in later versions of LV but I have not seen any documentation of this.



Message 1 of 7
(3,686 Views)

Good Afternoon Garvacious,

 

When you say the pop-up menu, I assume you mean the menu that appears if you right-click on the control.

 

I just tried this in LabVIEW 8.6.1.  My mouse cursor position reads 0,0 when the mouse is over the control and -1,-1 when the mouse is not over the control.  This is a bug.  I have filed the appropriate internal documentation (Corrective Action Request #167102) so that R&D is aware of the issue.

 

Thank you for letting us know about this behavior.  I am sorry for any inconveniencce this bug has caused you.

0 Kudos
Message 2 of 7
(3,643 Views)

I'm using LV 2009 on Windows XP and it still hasn't been fixed; i get -2147483648, -2147483648 both inside and outside the control. Was it fixed with 2010?

0 Kudos
Message 3 of 7
(3,301 Views)

Hello Snamprogetti,

 

As of today (LV 2010 SP1), a fix has not yet been implemented.

 

0 Kudos
Message 4 of 7
(3,293 Views)

It is also still broken in LabView 2014 SP1. The only fix is to delete the 2D Picture object and make a new one (copy and paste the control/indicator does not fix it)

0 Kudos
Message 5 of 7
(2,748 Views)
Solution
Accepted by rolfk

In LV2020, you get -2147483648, -2147483648. So not fixed.

 

There is a fix! 

 

Setting the zoom factor with the Zoom Factor property resets the behavior. The value doesn't need to change, so this works:

Zoom.PNG

Haven't tested this in older versions, but works wonders in LV2020.

0 Kudos
Message 6 of 7
(2,239 Views)

Fixes the problem in LV13 as well.

 

Just to make sure, this does not fix the bug! It is a workaround to recover from the bug. It's easier than replacing the control and reapplying all properties and cosmetic changes.

0 Kudos
Message 7 of 7
(2,235 Views)