Opening a lister from a button

I have a dual horizontal lister with several tabs pointing to different relevant folders for my current project.

I have save this as a lister layout called 'VC Latest'

I have set up a new button to load this lister, which uses the command

My problem is this. When I load the layout using settings > lister layouts, everything works fine and I see all of the tabs that I expect, and they are all pointing at the correct folders.

When I use my button however, the path for the window which was active when the button was pressed remains as it was. I would have expected it to inherit the path that was saved in the lister layout. (as if I used the menus to open it) :confused:

I am sure that there is a modifier somewhere within the Go command, but I am finding the help so confusing ... it seems to be written for somebody who has been with this great program from the start. ('this now does ...')

I do not want to include a path in the button's command since the 'current project' will be different next month.

Ideally, I would like to save the lister again using the same name and all buttons/shortcuts will then use the new project layout.

I would also prefer not to start a completely new lister (I have so many windows open that I am trying to cut back!)

Any thoughts (or even blindingly obviuos solutions!) would be appreciated.

Many thanks, Martin.

:blush: Oops

I knew it would be obvious ... sort of

it is not the go command but the prefs command

(but I am GOing, so perhaps not so obvious?)

but I am still not sure about it opening yet another window. There seems to be a layoutcloselisters command, but the help file implies that it closes all existing listers?
Is it possible to close the current lister only as part of opening a new lister?

[quote]• LAYOUTCLOSELISTERS/O[,yes,no]: This option is used in conjunction with the LAYOUT
option and lets you control whether existing Listers are closed or left open when you load a new Lister

The close command will close the current lister. It also has a number of arguments which allow you to modify it's behaviour.

[quote]From the manual, pg 154: The Close command is used to close Listers, exit the program or shutdown the entire system. The default
behavior of the command, with no options specified on the command line, is to close the active Lister.[/quote]

The problem is that if the Close command is the first line in the button all subsequent commands are ignored. Or if it's last, then the close affects the newly opened lister.

As you suggest, you can use the following command and arguments which will close all listers as it opens the new layout:


Your problem would be easily remedied by using Lister Styles instead.

Prefs - Layout - Lister Styles

Create a new style and configure it as required, including your tabs. Then create a button which loads this new style - the current lister will take on this style, rather than opening a new lister as Opus does with layouts.

Prefs STYLE=<name of your style>

Tanis: Thanks for the pointer ... but as usual it leads to more questions ...

  1. Setting up a lister style seems to take a lots of clicks, is there a way to import a lister, or use the current lister? Every month or so most of the paths will change.

  2. I have set up a style that loads 3 tabs into the right display, each tab pointiing to an absolute path. If I then click on the lister style tab these tabs open again. Click on the lister tab and the tabs open again. I now have 9 tabs, three for each path. Is there an option so that tabs are not opened if there is already a tab displaying the same path?

Many thanks


The command to save the current lister as a style is:


From the manual, pg 170:
This parameter lets you save the configuration of the current Lister as a new Lister Style. If no name is specified, Opus will prompt you for the name of the new Style.

You can't specifically force the style to not open tabs if they exist (again, as far as I know). There's an option to close ALL existing folder tabs when changing to a style which might suit your purposes.

The tickbox for this option is at the bottom right of the dialog you used to configure tabs for your style.

I know you didn't want to use a button with the Go command, since it'll be a hassle to keep editing it, but if that turns out to be the best option (e.g. you don't want to close existing tabs in the lister that you're changing) then you might like to know that the Go command has a "findexisting" argument to prevent it from opening duplicate tabs. For example:

[b]Go NEWTAB=nofocus,findexisting C:[/b]

If you have a fixed number of paths then you could make editing them a bit easier by using Aliases for the paths (Preferences / Favorites & Recent / Aliases). If the number varies then Aliases won't be much use.

Thanks folks .... have played, will play :smiley:

Does the 'Prefs STYLESAVE' command save the paths of the tabs, or is there a switch that I have missed?

You could probably create a button that does Prefs STYLE "VC Latest" on LMB, and does Prefs STYLESAVE "VC Latest" on RMB. The STYLESAVE command does indeed save/update folder tabs.

So basically, when your project changes to require a different set of folders, you'd position your tabs to those new folders then click RMB on your new button... done.

Edit note- you don't have to create your style through Preferences either. If you've opened your lister from your original saved 'Layout' with everything all set up the way you wanted it, you could click RMB on the Styles 'tabbar' and select Add style, name it what you want, followed by clicking RMB on the newly created Style and select Update. Also, I believe this sets the Close existing Folder Tabs option that Tanis was referencing in the Styles 'Tabs' dialog by default as well...

Thanks for all the help ... I have got it sorted through creating a lister style with several tabs ... and then updating the style by right clicking the style tabs and then choosing update ... simple!

There were one or two things that did not seem to operate as I would have expected them to bt that was probably me ... with one exception?

Edit a lister style and one of the options is to change the folder. I could easily use an alias here with no problems, eg. '/vclatest\graphics'.
But ... press the Tab button, and edit the tabs within the lister layout and I was not able to use an alias.
e.g. entering '/vclatest\graphics' for example turn into 'c:\vclatest\graphics' i.e. the / became \ which then ignored the alias.

Guess it's an oversight in how the styles->tabs editor handles things. If you want to use alias to update styles tabs, it looks like you'll have to to inside an active lister, then use the RMB->Update styles maneuver...