View problem

Things you’d like to miss in the future...
Post Reply
JimInWoodstock
Posts: 8
Joined: 19 Mar 2018 16:20

View problem

Post by JimInWoodstock »

There appears to be a problem with the view menu function.
Go to view, views, list - the view changes to the list view and the list view is "checked"
Do it again with the same selection - the view changes to the Details view and the "Details view is checked".

So the bug appears to be that is the "checked" view is clicked, the view changes to the "Details" view.

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

Re: View problem

Post by highend »

This is actually a feature. It switches back to the last used view when you click the checked item again...
One of my scripts helped you out? Please donate via Paypal

JimInWoodstock
Posts: 8
Joined: 19 Mar 2018 16:20

Re: View problem

Post by JimInWoodstock »

Thanks. This is only a problem when scripting. Lets suppose that my current view is "list" on c:\programs". I want a script to always go to a specific drive/folder in list view. When I execute the script, since the last view "list", the new drive/folder comes up in "details" view.

So the actual script is:

"Download-Newer - Decending" ::goto "g:\download-newer"; sortby m; #304

So my current view is "list" on c:\programs" and I execute the script.

Since the current view is "list" and I am using the #304 to change the new view to "list", the view now changes to "details" view.

If there is another way to write the script, I would appreciate the help.

I have around a dozen scripts in the favorites folders to navigate to a specific drive/folder and they all have this same problem.

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

Re: View problem

Post by highend »

Sure

Code: Select all

get("view")
returns the number for the current view so you can use a ternary or if / else combo to switch to the correct one
E.g.:

Code: Select all

"Download-Newer - Decending" ::goto "g:\download-newer"; sortby m; if (get("view") != 2) { #304; }
One of my scripts helped you out? Please donate via Paypal

JimInWoodstock
Posts: 8
Joined: 19 Mar 2018 16:20

Re: View problem

Post by JimInWoodstock »

Thanks,

This fixes the problem nicely.

Post Reply