LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Panel vs Cursor Coordinates

I'm having a problem understanding the relationship between cursor
position and front panel object positioning. I'm using the "get cursor
position" vi to give me the coordinates on a 1024x768 monitor. But,
when I plug those numbers into the "position attribute" for an
indicator, it isn't even close to being in the right location. Why?
What's the secret code? Is there a known grid for all front panels
(1024x1024) ? And somehow I need to translate from my graphics card
resolution?

Thanks,
Bill
0 Kudos
Message 1 of 2
(2,755 Views)
Bill,

The cursor position you got is in screen coordinates
(top-left cornor of your screen is 0,0, bottom-right
corner is 1024,768). You have to convert it to client
coordinate (top-left corner of the client area of your
front panel is 0,0). And then convert to LabVIEW
coordinate, a vertical shift of the toolbar height.
And then you can use it for position attribute.

If you're using LabVIEW5.1, you can download the
screen to client convert following this link:

http://gtoolbox.yeah.net



George
George Zou
0 Kudos
Message 2 of 2
(2,755 Views)