c# 4.0 - Access User's Possible Screen Resolutions - C# 2010 -
Thank you in advance for your help.
I am thinking that how can I access the screen resolution is available on a user's PC. I would like to get a list of all available offers and will also determine what the user is currently doing.
I believe that you call PInvoke in the User32.dll < Strong> EnumDisplaySettings can make API calls. [DllImport ("user32.dll")] Public static extern bool EnumDisplaySettings (string device name, int modem, ref DEVMODE devMode);
See examples.
You will definitely run in complexity with the dual monitor system, but you can do this to get the current screen
System.Windows.Forms.Screen.PrimaryScreen Bounds.Width
I think you were talking about an executable and not the ASP.NET app, but if you need the screen to resize in javascript, you You can use the screen object
screen.width; Screen.height; Screen.colorDepth;
Comments
Post a Comment