public static void SetActiveWindow(IntPtr hwnd) { try { User32Interop.SetActiveWindow(hwnd); } catch { } }