Page 1 of 1
exclude files with Live Filter
Posted: 30 May 2024 15:36
by 7iben
I would like to be able to exclude files using the Live Filter function. Is this already possible?
example:
001.pdf
001_test.pdf
002.pdf
002_test.pdf
003.pdf
003_test.pdf
004.pdf
004_test.pdf
Here I would like to hide all files with test in the file name. So that only the remaining files are displayed one below the other.
This would enable faster file selection.
Re: exclude files with Live Filter
Posted: 30 May 2024 16:15
by highend
Sure it is, read the help about visual filter syntax for the NOT operator...
Re: exclude files with Live Filter
Posted: 31 May 2024 06:29
by jupe
Before you reply it doesn't work, make sure this is enabled
Configuration | Find and Filter | Filters & Type Ahead Find | Live Filter Box | Enable extended pattern matching
Re: exclude files with Live Filter
Posted: 01 Jun 2024 15:39
by 7iben
I found the following command:
!*test*
This also works well. It's just a bit time-consuming and fiddly to enter the command and put the word between the stars.
Is it possible to filter and exclude multiple words? I haven't managed that yet. So the above command two or three times with different words?
And is it possible to call up the last applied filters via the filter symbol.
At the moment this only works for me with the last filter as long as I don't close Xyplorer.
Re: exclude files with Live Filter
Posted: 01 Jun 2024 15:54
by highend
I haven't managed that yet. So the above command two or three times with different words?
The examples include such a case^^
And if it's too much work to type everything in, write a script that creates the necessary pattern for such cases...
Re: exclude files with Live Filter
Posted: 02 Jun 2024 17:34
by 7iben
a script would be ideal. So you only have to enter the words that you want to filter. Unfortunately I can't write scripts. Can someone help me?
Re: exclude files with Live Filter
Posted: 02 Jun 2024 17:44
by highend
Code: Select all
$words = input("Enter ','-separated words", , "hello,world", "e");
$pattern = "!(";
foreach($word, $words, ",", "e") { $pattern .= "*" . trim($word) . "*" . ";"; }
copytext trim($pattern, ";") . ")";
Re: exclude files with Live Filter
Posted: 02 Jun 2024 20:52
by 7iben
Thank you. Is there also a possibility for the script to enter and confirm directly in the filter field. At the moment the filter is not applied but is just copied to the clipboard.
Re: exclude files with Live Filter
Posted: 02 Jun 2024 21:37
by highend
Replace the last line with
filter trim($pattern, ";") . ")", 1+4+8;
?
Re: exclude files with Live Filter
Posted: 07 Jun 2024 23:41
by 7iben