09-20-2016 02:23 PM
Is there a function that tells me whether my secondary monitor is to the left or right of the primary monitor?
I am drawing 2D objects on a vi which will be displayed either on the primary or secondary monitor to the left or right, and have used the FP.monitor bounds property to re-size the vi and find the origin. But this only gives me the total screen width - I can only tell if the workspace is one or two screen sizes long, not where they are. I have tried to work this out using the panel.bounds but this is a little messy.
Thanks
Solved! Go to Solution.
09-20-2016 02:55 PM
Are you on Windows?
If so, you can use .NET to find out more information. Here's an example to get you started:
That first one is System.Windows.Forms.Screen and you can explore the other properties and such until you get the information you want.
09-20-2016 03:42 PM
Actually, it would really surprise me if even Windows can tell whether Monitor 1 is to the left or right of Monitor 2. Here's a thought experiment -- take any dual-screen system with, say, a Desktop showing on the left Monitor and a picture showing on the right Monitor. Now, pick up the two monitors and physically switch their positions, leaving them connected. Don't you expect the images to move with the Monitors, regardless of which was Monitor 1 or Monitor 2?
Maybe I am misunderstanding what you are trying to do ...
Bob Schor
09-20-2016 05:06 PM
When you set up multiple displays in the control panel, you tell them where they go for purposes of moving the mouse cursor between them seamlessly. Sure, if you lie to Windows in the control panel, your monitors will read as being in the wrong places. But as long as you set them up here honestly:
Then you should be able to get their relative locations.
09-21-2016 05:45 AM
Thanks Kyle. That's exactly what was I after. And I have just learnt to call Windows comands usign .NET 🙂