Button To Toggle Folder Mixing

Hi

Trying to create a button to toggle Folder Mixing in the active lister. I thought this might do it:

Set GROUPFOLDERSATTOP=Toggle

But for some reason the button is greyed out. I know I could create a specific folder format for it, but I might not want to override other settings.

Am I using the right command?

Cheers
Matt

Understandable confusion! That command is specifically for when the file display is "grouped", and controls whether the group that contains folders appears before all other groups or not.

The command you probably want is Set SORTORDER, which controls the mixing of files and folders (files on top, folders on top, or files and folders mixed together).

It's not a straight "toggle" though since it has three states - you can use Set SORTORDER=Cycle to cycle through the different modes. If you want a command to toggle between two modes you can use something like this (which will switch between "folders first" and "mixed"):

@toggle:if SORTORDER=folders
@ifset:SORTORDER=folders
Set SORTORDER=mixed
@ifset:else
Set SORTORDER=folders

Awesome! Thanks Jon!

Maybe consider adding Set SORTORDER=Cycle to the right click Lister Column Header context menu?


Regards, AB

I'm many years late this thread. i was just trying to figure how to make mixing files and folders toggle. I've copied that @toggle:if code to a button and put a hotkey to it. but it doesn't seem to be working...

has the maybe the context changed because were on v13 now?

That command was supposed to be on separate lines, changes to the forum sometime in the past 7 years broke it unfortunately. I've edited the post to fix it up.

awesome! thank you much! its working now
i was just starting to separate the lines just trying to make sense of the commands. its working now

I'm endlessly amazing at the power of Dopus. Wish i understood scripting commands better. little by little i guess. making my own menus via forum such as this.

1 Like