Is there a predefined button/menu to show today created files/folders only? By pressing it I want to see (not to select) today files/folders only. By unpressing it all the filters must return to the previous state in accordance with folder format.
Unfortunately this solution isn't universal enough, because Filter Bar's Evaluator must be enabled in Preferences by default. But Evaluator being turned on avoids quick type-and-find feature (Partial matching) of Filter Bar.
How can I modify button to use it with disabled Evaluator?
Better, but Evaluator remains on after any button use. But my goal is to keep Evaluator off after button's work to able quick type-and-find Partial matching feature (doesn't work while Evaluator being enabled). Is it way to restore Evaluator off-status after pressing the button?
Such "script" doesn't work for me too:
Set QUICKFILTERFLAGS=evalon QUICKFILTER ?todayfiles
Set QUICKFILTERFLAGS=evaloff
option explicit
' Clear Evaluator Flag
' (c) 2024 Yourez
' This is a script for Directory Opus.
' See https://www.gpsoft.com.au/endpoints/redirect.php?page=scripts for development information.
' Called by Directory Opus to initialize the script
Function OnInit(initData)
initData.name = "Clear Evaluator Flag"
initData.version = "1.0"
initData.copyright = "(c) 2024 Yourez"
' initData.url = "https://resource.dopus.com/c/buttons-scripts/16"
initData.desc = ""
initData.default_enable = true
initData.min_version = "13.0"
End Function
' Called when the quick filter is changed in a tab
Function OnQuickFilterChange(quickFilterChangeData)
DOpus.Create.Command.RunCommand("Set QUICKFILTERFLAGS=evaloff")
End Function
It works bad. After pressing my TodayOnly button lister shows today only files, but only for 0.5 sec, and then today files disappear at all. Meanwhile Evaluator flag turns off.
Your script turns off Evaluator mode on every filter change. That means it will turn it off even when you want it on. It should check what the filter is set to first to see if it should make the change or leave things alone.
I turned to JS, it's more clear for me. Now it works. Guys, thanks a lot for help!
// Clear Evaluator Flag
// (c) 2024 Yourez
// This is a script for Directory Opus.
// See https://www.gpsoft.com.au/endpoints/redirect.php?page=scripts for development information.
// Called by Directory Opus to initialize the script
function OnInit(initData)
{
initData.name = "Clear Evaluator Flag";
initData.version = "1.0";
initData.copyright = "(c) 2024 Yourez";
// initData.url = "https://resource.dopus.com/c/buttons-scripts/16";
initData.desc = "";
initData.default_enable = true;
initData.min_version = "13.0";
}
// Called when the quick filter is changed in a tab
function OnQuickFilterChange(quickFilterChangeData)
{
var tab = quickFilterChangeData.tab;
if (tab.quickfilter.filter == '') DOpus.Create.Command.RunCommand("Set QUICKFILTERFLAGS=evaloff");
}