Learn when you want, where you want with convenient online training courses. Sign up now!
Experts Exchange Solution brought to you by
"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.
setWindowPos(SecAppHandle, HWND_TOPMOST, x1, y1, 0, 0, SWP_NOACTIVATE or SWP_NOSIZE or SWP_NOZORDER);
Open in new window
procedure TfrmMain.actDuplicateDisplaysExecute(Sender: TObject);
FSlideShowX := Screen.Monitors.Width; // remembers width of primary monitor (was initialised to -1)
ShellExecute(0, 'open', 'DisplaySwitch.exe', '/clone', '', 0); // switches display into Duplicate mode
Application.BringToFront; // ensures this app comes to the front
procedure TfrmMain.actExtendDisplayExecute(Sender: TObject);
if Screen.MonitorCount > 1 then begin // only execute this if there is more than one monitor
ShellExecute(0, 'open', 'DisplaySwitch.exe', '/extend', '', 0); // switch display into Extended mode
hSlideShowWindow := GetWindowHandle('Slide Show'); // find the powerpoint slide show window handle
if ((hSlideShowWindow <> 0) and (FSlideShowX > -1)) then begin // if the slide show window was found and its X position has been previously stored
SetWindowPos(hSlideShowWindow, HWND_TOPMOST, FSlideShowX, 0, 0, 0, SWP_SHOWWINDOW); // set the new position of the slide show window
This course teaches how to install and configure Windows Server 2012 R2. It is the first step on your path to becoming a Microsoft Certified Solutions Expert (MCSE).
SetWindowPos(hSlideShowWindow, HWND_TOPMOST, FSlideShowX, 0, 0, 0, SWP_SHOWWINDOW);
while True do
scr := TScreen.Create(Application);
monNum := scr.MonitorCount;
if monNum > 1 then Break;
SetWindowPos(hSlideShowWindow, HWND_TOPMOST, FSlideShowX, 0, 0, 0, SWP_NOACTIVATE or SWP_NOSIZE or SWP_NOZORDER);
MoveWindow(PPHandle, 0, 0, (r.Right-r.Left), (r.Bottom-r.Top), True);
Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.
From novice to tech pro — start learning today.
Premium members can enroll in this course at no extra cost.