Lister Button

I've created a new lister with dual display and trees. I've created a button on the toolbar. I would like the button to open the lister in the current lister when pressed.

How do I do this?

I didn't realize that I've already done this before. However I would like the lister to open in the same lister so that I don't have multiple listers open.

Easiest way, if you're already using a layout for this and always only want one window open, is to make the command close existing windows when it opens the new layout:

Prefs LAYOUT="My Layout" LAYOUTCLOSELISTERS=yes

Is there a way to use the existing window without closing it to load the lister?

Yes, using the LAYOUTTHISLISTER argument:

Prefs LAYOUT="My Layout" LAYOUTTHISLISTER

[quote="jon"]Yes, using the LAYOUTTHISLISTER argument:

Prefs LAYOUT="My Layout" LAYOUTTHISLISTER

The button does not work with that code!

Whats the name of your saved layout? And did you replace "My Layout" with that name?

Yes I have been replacing the "My Layout" with the name of the layout that I want to use.

I even put an S at the end of LAYOUTTHISLISTER but that brings up the preferences for all the layouts.

This will apply more aspects of the layout to the current lister:

Prefs LAYOUT="My Layout" LAYOUTTHISLISTER=size,pos,paths

If it's still not doing what you want, please tell us exactly what you want to do and what you want to change in the window. (It may also be easier to use commands which change things directly, and not use a layout at all, but that will depend on what you want to change.)

That is what I wanted it to do. Thanks Leo.

Also thanks Jon and ktbcrash.