In the help it says: "The copy filter is local to the Lister, and it remains enabled in that Lister until it is turned off or the Lister is closed. " Indeed the behaviour of the program appears to mirror this.
However, I can't see how this can be a good idea. I have been finding myself accidentally copying files that should not be copied since the copy filter inevitably gets turned off because either
I have moved on to another lister and navigated back to directory that I was working and the copy filter has been turned off
I have used a saved lister layout and the copy filter setting is not recorded in the lister layout data.
Can I make a suggestion:
Either store the copy filter in the lister layout info or
Make it so that a copy filter is remember against a particular folder irrespective of whether the lister was opened, closed, etc.
It sounds like you want the filter to always be applied for certain copy operations?
If so, the lister Copy Filter probably isn't the right thing to use. That is intended for ad-hoc, temporary use where you turn it on, do a special copy, then turn it off.
For what you're doing, I recommend saving the filter you have defined and then creating a button (or hotkey, drag & drop action, etc.) which runs Copy FILTER="My Filter Name" and then use that instead of the normal Copy button when you need to copy using that filter.
(You could also make the normal Copy button do this if you click it while holding Ctrl, for example. If you edit the button you'll see it already has an example where holding Shift changes the behaviour.)
I do not entirely know why this functionality was changed. I liked the old way It feels like the pendulum may have swung too far in the other direction now.
I am not sure if this is a bug or I am doing something silly. I have changed the command being run on my copy update all button as per your suggestion.
The command is now "Copy FILTER="ASPX Dist" UPDATEALL" However the copy filter is simply not applied when I click the button. It does a copy like the Filter is not turned on.
This is a filter that we have used successfully for MANY years. It is an "ASP.NET" filter to effectively distribute ASPX.NET files and DLLs and avoid other gumph like .configs etc when deploying an ASP.NET application via FTP.
I fear that your request for this is suggesting that it is a problem with the filter itself - I can guarentee this is not the case.
The file is attached - although it is so long it is cut off.
Thanks, and I agree if the filter works elsewhere then it's unlikely to have an error. Just wanted to ser ut in case sonething jumped out at me.
Have you tried removing the UpdateAll argument to see if the command works when doing a normal copy with filtering? I guess it's possible UpdateAll ignores the filter, but I'm not sure and not at a PC to check at the moment.
Set the filter to just match *.txt and see if that successfully copies only text files to confim that "Copy FILTER=xyz" is working at all for you.
That should work, so then make the filter a bit more like the one you want to use for real and see if something makes it stop working.
Oh, one important thing to note (which I only just remembered was relevant): Copy filters only affect what gets included within the selected sub-directories. If a file is selected at the top-level, it will always be copied. (You can filter things out at the top level first using the same filter and the Select command.)
I think you have nailed it. Your initial suggestion of simply going "Copy FILTER="ASPX Dist" UPDATEALL" did not work because of this evidently does not operate on the top level files and folders (right or wrongly - which I would argue is insanely wrong but I am not getting into that argument). As such I changed the commands to be
My post (subject) is related so i am writing here..
I would like to create a copy button which sets the copy filter on, then asks me to modify the copy filter settings, and finally does the copying. and as a last step clears the copy filter. My code
Set COPYFILTER=On
Copy
Set COPYFILTER=Off
doesnt do the trick 100%. Files are copied using the filter settings .. without asking me to modify/set the filter. Whatever is saved as copyfiltersetting is directly used. Please help me correct the code, thanks!
[quote="jon"]
Changes in 10.0.0.3:[ul]
[li]A button combining Set COPYFILTER=on with the Copy command now correctly applies the filter[/li][/ul][/quote]
Thanks jon. My primitive button (emulating Total Commander's default Copy dialogue) works now!