Пример #1
0
        private void MinimizeAllRemoteDesktopConnections()
        {
            var rdHandles = ExternalAppController.GetWindowHandleByTitle("- Remote Desktop Connection");

            foreach (var handle in rdHandles)
            {
                ExternalAppController.SetWindowState(handle, AppState.SW_SHOWMINIMIZED);
            }
        }
Пример #2
0
        private static void ShowRemoteDesktopByTitle(string title)
        {
            var rdHandles = ExternalAppController.GetWindowHandleByTitle(title);

            if (rdHandles != null && rdHandles.Count > 0)
            {
                var handle = rdHandles[0];
                ExternalAppController.SetWindowState(handle, AppState.SW_RESTORE);
            }
        }