Processing Ajax...

Title

Message

Confirm

Confirm

Confirm

Confirm

Are you sure you want to delete this item?

Confirm

Are you sure you want to delete this item?

User Image
William Shore
1 discussion post
RE: Windows 10 - Hi, I typically run a dozen apps at a time (not unusual, I know) but I really would like it if I could assign a specific shortcut (eg, Win-5, or CTRL-E) so that the App buried under the other dozen apps would move to the top and be the focused app. I do know about ALT-Tab and Desktops but, for example, I'd like to immediately switch my focus to Excel, or Firefox, or whatever. I'm having much trouble figuring out how to accomplish this (I think) simple thing. I was thinking maybe this was something - if Win10 can't do natively - that DisplayFusion (or one of the company's apps) could do but I don't see how. Thanks for any and all help!
Aug 31, 2018  • #1
Keith Lammers (BFS)'s profile on WallpaperFusion.com
On the Settings > Functions tab, you can add a Scripted Function that would do this. Here's some sample code for bringing Excel to the front:

Code

using System;
using System.Drawing;

public static class DisplayFusionFunction
{
    public static void Run(IntPtr windowHandle)
    {
        BFS.Window.Focus(BFS.Application.GetMainWindowByFile("*excel.exe"));
    }
}


Hope that helps!
Sep 5, 2018  • #2
User Image
Marc Kleinmann1
1 discussion post
Is there a way to use a similar script to bring an active zoom video conference window in focus? When I use the zoom.exe file it focuses on the zoom application window, but not on the active video conference in progress.
Apr 18, 2020  • #3
Keith Lammers (BFS)'s profile on WallpaperFusion.com
Does the active conference window have something in the Window Title that would identify it uniquely from the main window? If so, you could use this instead:

Code

BFS.Window.Focus(BFS.Application.GetMainWindowByText("*unique window title text*"))
Apr 18, 2020  • #4
User Image
Andrew Burbidge
3 discussion posts
I'm also looking to bring the Zoom meeting window to the front, but putting in the window text "Zoom Meeting" (as it appears in the window title bar) throws the following error:

using System;
using System.Drawing;

public static class DisplayFusionFunction
{
public static void Run(IntPtr windowHandle)
{
BFS.Window.Focus(BFS.Application.GetMainWindowByText("Zoom Meeting"));
}
}

"'Application' does not contain a definition for 'GetMainWindowByText'"
• Attachment: ZoomMeeting.png [2,037 bytes]
ZoomMeeting.png
ZoomMeeting.png
Mar 22, 2023  • #5
Owen Muhlethaler (BFS)'s profile on WallpaperFusion.com
Hi Andrew,

Try this line instead: BFS.Window.Focus(BFS.Window.GetWindowByText("Zoom Meeting"));
Mar 22, 2023  • #6
Subscribe to this discussion topic using RSS
Was this helpful?  Login to Vote(1)  Login to Vote(-)