I'm trying to change resolution of my display using win32 call ChangeDisplaySettings with the following way:
DEVMODE devmode; devmode.dmPelsWidth = 1024; devmode.dmPelsHeight = 768; long result = ChangeDisplaySettings(&devmode, DM_PELSWIDTH || DM_PELSHEIGHT); qDebug() << "RESULT OF CHANGE DISPLAY :"<< result; Always I get the same result value, -2, that indicates "display mode stored in the Registry". The source of this info is the following:
http://www.codeproject.com/Articles/36664/Changing-Display-Settings-Programmatically
The issue here is that my resolution DOES NOT CHANGE never. Any idea why I cannot do that?