I have serious problems to detect screen resolution under vista64. I have 2 methods using C# to find the resolution backside of a webpage. Client side resolution using javascript is fine but backside nothing is correct.
int deskWidth = SystemInformation.PrimaryMonitorSize.Width; return 1024
IntPtr hdcSrc = User32.GetDesktopWindow(); int width = GetDeviceCaps(hdcSrc, HORZRES); return 1024
After many changes is screen res. these methods are always returning the same value 1024开发者_如何学编程. In the past these methods worked fine but windows update is here.
Can someone help me to fix this issue or suggest another way to get the resolution that works?
Many thanks for your answers.
It is not possible to detect the browser's screen resolution directly on the server.
精彩评论