Close Tab By Name ?

Discuss and share scripts and script files...
klownboy
Posts: 4052
Joined: 28 Feb 2012 19:27

Re: Close Tab By Name ?

Post by klownboy »

Thanks again Don, it's working great. :tup:
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440

jupe
Posts: 2669
Joined: 20 Oct 2017 21:14
Location: Win10 22H2 120dpi

Re: Close Tab By Name ?

Post by jupe »

I have been having issues since this change was made, I was waiting to see if .0214 would resolve it but it hasn't, If I run this command e tab("get", "caption"); I get the below error. I tried to repro in fresh and at first I couldn't, but it made me notice that XY isn't returning the correct tabs data, it always returns the first tab.

So to repro in fresh, in Pane 2, add a tab so there are 3, then run it with that tab open, it returns "Desktop" (first tab), if you then rename that 3rd tab and move it to first position and rerun the script, it will then give that error.

Below is a basic repro script for fresh if needed, it demonstrates that the correct tabs data isn't being returned, by renaming tab1 when active tab is tab2, and then also shows the error afterwards.
focus "P2"; tab("rename", "XY"); e tab("get", "caption");

2023-10-29_072056.png
2023-10-29_072056.png (6.37 KiB) Viewed 356 times

Additionally, and I think it will be resolved when the aforementioned issue is because it only started in this same timeframe, but I am seeing this tab color matching issue again, I assume because the wrong tab ID is being reported to XY.
2023-10-28_041354.png
2023-10-28_041354.png (1.89 KiB) Viewed 335 times

klownboy
Posts: 4052
Joined: 28 Feb 2012 19:27

Re: Close Tab By Name ?

Post by klownboy »

e tab("get", "caption","23"); works whenever you provide the index of the tab, but not when it's supposed to get the current tab caption (i.e., no index provided).
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440

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

Re: Close Tab By Name ?

Post by admin »

Yep. Fix on the way. :tup:

klownboy
Posts: 4052
Joined: 28 Feb 2012 19:27

Re: Close Tab By Name ?

Post by klownboy »

Looking good for me. :tup:
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440

Post Reply