Filters 101

In Preferences, I added a Content Type called "Files Only" with the intention of creating a view that excludes folders. In the Filters section of the Edit dialogue for "Files Only" I checked the bottom Hide Filter and entered . in the Folders: field. This had no effect when applied to a lister that contains both files and folders. I went back and checked all of the associated attributes boxes in the Hide Filter section and now the "Files Only" Content Type has the exact opposite effect of what I expected - in other words it shows folders only, instead of files only.

Could some kind person tell me what I'm doing wrong. TIA.

Regards, AB

Interesting try but Content Type is not for this:) Content Type works by reading the folder thenlooking at the files then changing view mades etc. It is not desigend to do this type of thing. You could use a normal Folder format for a specific path to do this but probably not what you want.

Easiest would be to add Show Folders Field or better Hide Folders Field to a toolbar then use this with wildcard pattern to hide specific folders folders when you wanted.

[quote]
greg wrote:
Easiest would be to add Show Folders Field or better Hide Folders Field to a toolbar then use this with wildcard pattern to hide specific folders folders when you wanted.[/quote]
Actually that is specifically what I had hoped to avoid by using this technique. Given that Content Type can be used to filter what files are shown (e.g. Documents) it seemed like an obvious way to filter what folders are not shown.

Regards, AB :confused:

I actually would have thought somethign like this would work also since the filters that you specify in a Content Type folder format are actually just internally acted upon by the regular show/hide filter by Opus anyway... but especially because the content type filters seems to work this way anyway, why were you 'trying to avoid' using them to achieve what you wanted here? Just curious...

I'm still not totally sure what you're trying to do, but I think I often do something similar to what you're trying. I created a button that will toggle whether or not folders are shown in my lister. Here's the button:

[code]

<?xml version="1.0"?> Hide Folders Hides all folders 101 Set HIDEFILTERFOLDERS=* [/code]

If you don't want to have to toggle, you can choose which folders you want to see only files in, and change the folder options for that folder. If you do that, though, it's still a decent idea to have the button available just in case you need to see the folders at some point, then you can easily turn the filter off. Navigate to the folder where you only want to see files, open the folder options for that folder, click the "Filters" tab, and in the hide folders field at the bottom type one single asterisk. No dots, as that means the folder name would have to have a dot in it. Dots are used only for FILE filters, not for FOLDER filters. Instead of typing "." into the hide folders field, type "*"

I hope that clears things up a bit. Let me know.

--chriscrutch

Thanks chriscrutch. The perfect solution.

Steje - I have a lot of buttons on my DOpus window and am therefore short of space. A filter box for folders is a luxury I can't afford. Chris's solution is ideal.

Thanks to all, AB

ah - yes, I'm ok with toolbar space under my normal working situation, but when I undock the laptop and have to look at it's LCD then it's quite annoying to have to scroll the toolbar so I hear you aussie!

That's why I've got a boat load of hotkey assignments to do stuff like this as well... I wonder if anyones made a request for mouse gesture type functionality... hmmm.

steje,

I've heard people ask mouse-gesture requests for Opus. No idea if they're looking into it for a future version or not, but in the meantime....there are a couple of programs that provide system-wide mouse gesture support. StrokeIt can be found at sensiva.com/

I haven't tried any of them, and Sensiva in particular looks pretty basic.

--chriscrutch

Can someone tell me how and where I add the button script above? I have created a new button, brought up the edit window, clicked on advanced and pasted the text. When I click, I get an error re <?XML... from windows.

Please help.

Thanks,

Lp,

Some people open up the toolbars .DOP file in the button directory and copy out the complete information for the button. The actual command that's being run in the button above is just what's between the XML 'instruction' tags: Set HIDEFILTERFOLDERS=*

You don't have to edit the .DOP file, just go to Customize mode, right-click a button and do Copy. If you then paste into a text editor (without exiting Customize mode) you'll paste the XML for the button.

Another person can then copy that XML (e.g. from a forum post like the one above) into their clipboard, switch Opus into Customize mode, right-click a toolbar and select Paste to recreate the button instantly.