View problem

Things you’d like to miss in the future...
Forum rules
You might want to read this if you're looking for priority service

:info: Please Include The Following Information
1) Your XYplorer Version (e.g., v28.00.0801)
2) Your Windows Version (e.g., Win 11)
3) Your Screen Scaling Percentage (e.g., 125%).

:info: Use Your Profile Or Signature
We strongly recommend adding your Windows Version and Screen Scaling Percentage to the Location field in your Profile or to your Signature. That way, you only have to type them once, and we won't have to search for that vital information.

:info: How To Attach Images
When attaching an Image, please use the Attachment tab at the bottom of your post and click "Add files".
Post Reply
JimInWoodstock
Posts: 12
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: 15016
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: 12
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: 15016
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: 12
Joined: 19 Mar 2018 16:20

Re: View problem

Post by JimInWoodstock »

Thanks,

This fixes the problem nicely.

Post Reply