XYplorer window title with multiple instances

Features wanted...
Post Reply
XAlphaClub
Posts: 6
Joined: 09 May 2023 14:11

XYplorer window title with multiple instances

Post by XAlphaClub »

Hello

When you open multiple XYplorer instances by command line, they have the same name for Windows, even if you use the /title parameter and set the title bar template accordingly. This makes it impossible to use an external script to distinguish these instances (e.g. to close one without closing the others via taskkill). Steps to reproduce :

From XYplorer :
Configuration / Colors & Styles / Templates / Title bar --> <title>
Save parameters
Quit XYplorer

From command line :
"C:\Program Files (x86)\XYplorer\XYplorer.exe" /title="test1"
"C:\Program Files (x86)\XYplorer\XYplorer.exe" /title="test2"
"C:\Program Files (x86)\XYplorer\XYplorer.exe" /title="test3"

From PowerShell :
Get-Process | Where-Object { $_.MainWindowTitle } | Select-Object MainWindowTitle

Result :

All XYplorer instances have the same MainWindowTitle "XYplorer" instead of "test1 XYplorer", "test2 XYplorer" , "test3 XYplorer" (see screenshot below)
Could it be possible to transmit the /title parameter to Windows (see taskkill WINDOWTITLE parameter) ?

Thanks
Attachments
WindowTitle.jpg
WindowTitle.jpg (60.53 KiB) Viewed 1186 times

admin
Site Admin
Posts: 63413
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: XYplorer window title with multiple instances

Post by admin »

<app> is mandatory in the template. So set the template to <app> - <title>.

highend
Posts: 14118
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: XYplorer window title with multiple instances

Post by highend »

That's not the problem.

The powershell script reports:

Code: Select all

MainWindowTitle
---------------
C:\Windows\System32\cmd.exe
Windows PowerShell
Windows Input Experience
XYplorer
XYplorer
XYplorer
While the three started instance all have a different window title (with the <app> - <title> template used)

Code: Select all

xyplorer.exe /title=hello1
xyplorer.exe /title=hello2
xyplorer.exe /title=hello3
One of my scripts helped you out? Please donate via Paypal

admin
Site Admin
Posts: 63413
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: XYplorer window title with multiple instances

Post by admin »

Hm, isn't that a powershell problem? I don't know another way to set the title.

XAlphaClub
Posts: 6
Joined: 09 May 2023 14:11

Re: XYplorer window title with multiple instances

Post by XAlphaClub »

admin wrote: 18 Nov 2024 16:55 Hm, isn't that a powershell problem? I don't know another way to set the title.
I think there is a hidden way : look to my PS screenshot in the top post. there is a line "Nircmd ... Moziilla Firefox". At this moment, I was on Nircmd site, using Firefox. And Firefox added title "Nircmd ..." to it's own app name.
But unfortunately I don't know the way ...

admin
Site Admin
Posts: 63413
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: XYplorer window title with multiple instances

Post by admin »

powershell should report what's written in the main window titlebar. I don't know why it does not. Maybe it cannot handle 32-bit windows anymore?

XAlphaClub
Posts: 6
Joined: 09 May 2023 14:11

Re: XYplorer window title with multiple instances

Post by XAlphaClub »

It's a possibility. Nevertheless, I found a barbaric way to get around this problem: copy XYplorer.exe to XYplorerProjectMars.exe, XYplorer.ProjectArcturus.exe... And PS returns these names well.
Very dirty. But woks fine :party:

Post Reply