Reputation: 45761
I am using VSTS 2008 + C#. Is there any way to get the informaiton like, whether we are currently in dual monitor mode, how much is the current resolution of each desktop?
BTW: there are two modes of dual screen, duplicate screen or extended screen. I need a solution as well to distinguish between the different modes.
thanks in advance, George
Upvotes: 3
Views: 2055
Reputation: 18184
System.Windows.Forms.Screen.AllScreens
Gets an array of all displays on the system.
The property Primary
Gets a value indicating whether a particular display is the primary device.
And the Bounds property may be the solution for the rest.
System.Windows.Forms.SystemInformation.VirtualScreen Property
Might be usefull for you, to determine if the primary monitor is cloned or extended.
VirtualScreen resolution higher than the ones of primary -> extended...
VirtualScreen resolution = the ones of primary -> cloned...
Upvotes: 5
Reputation: 421968
System.Windows.Forms.Screen
provides you with screen data. Duplicate screen is not really considered another screen from an application point of view.
Upvotes: 2