Binary Fortress
Binary Fortress Software
CheckCentral
ClipboardFusion
CloudShow
CloudShow Manager
DisplayFusion
FileSeek
HashTools
LogFusion
Notepad Replacer
Online Base64 Decoder
Online Base64 Encoder
Online JSON Formatter
ShellSend
TrayStatus
VoiceBot
WallpaperFusion
Window Inspector
More Apps...
DisplayFusion
CheckCentral
CloudShow
ClipboardFusion
FileSeek
TrayStatus
VoiceBot
WallpaperFusion
Display
Fusion
by Binary Fortress Software
Download
Download
Change Log
Download Beta
Beta Change Log
License (EULA)
Features
Free vs Pro
More
Screenshots
Scripted Functions (Macros)
Languages
Help
Help Guide
FAQ
Discussions
Contact Us
Find My License
Mailing Address
Advanced Settings
Purchase
Login / Register
WARNING: You currently have Javascript disabled!
This website will not function correctly without Javascript enabled.
Title
Message
OK
Confirm
Yes
No
Move All Windows from Monitor 2 to the Current Monitor
Return to DisplayFusion Scripted Functions (Macros)
Description
This script will move all visible windows from monitor 2 to the monitor that the mouse cursor is currently on.
Language
C#.net
Minimum Version
9.1+
Created By
Keith Lammers (BFS)
Contributors
-
Date Created
Dec 22, 2017
Date Last Modified
Dec 22, 2017
Scripted Function (Macro) Code
Copy
Select All
using System; using System.Drawing; public static class DisplayFusionFunction { public static void Run(IntPtr windowHandle) { // Set the Monitor ID you want to move the windows from uint monitorID = 2; // Loop through the visible windows on the monitor and move them to the monitor that has the mouse cursor foreach (IntPtr window in BFS.Window.GetVisibleWindowHandlesByMonitor(monitorID)) { BFS.DisplayFusion.RunFunctionWithWindowHandle("Move Window to Current Monitor", window); } } }