I turn my monitors on and off by using the following code:
[DllImport(\"user32.dll\")]
static extern IntPtr SendMessage(IntPtr hWnd, int Msg, IntPtr wParam,
I have found out this trick to work on windows 8.1
Turn them off
SendMessage(f.Handle, WM_SYSCOMMAND, (IntPtr)SC_MONITORPOWER, (IntPtr)MonitorShutoff);
Turn them on
SendMessage(f.Handle, WM_SYSCOMMAND, (IntPtr)SC_MONITORPOWER, (IntPtr)1);
According to MSN, "1" is to switch monitor to "Low Power" but it does the trick. The screen will not turn off anymore.