Customized Print Files... button not working quite right

I have been fighting with this button on and off for months & have simply given up trying to get it to work. I have been "making do" with the default Print Folder... button, set to my custom options. Couple of more clicks - and certainly less impressive when showing off DOpus to my co-workers :slight_smile: - but it gets the job done.

First, the button:

<?xml version="1.0"?> <button backcol="#0c34f3" display="icon" icon_size="large" textcol="none"> <label>Copy today&apos;s files</label> <tip>Copies any files modified today to the clipboard</tip> <icon1>#printfolder</icon1> <function type="normal"> <instruction>Print FOLDER AS=txt TO clip FLATVIEW=nofolders FORMAT=&quot;Names Only&quot; QUIET FILTER ModifiedTodayNoLocks</instruction> </function> </button>

Now, the purpose:
I need to be able to view a fairly complex and densely-populated directory structure and copy any contents modified today (or when-ever, but the current date is what happens most frequently) to a holding server. From there, someone else uploads the files to the production server (this is all due to a security audit...) The good folks in FTP-land have a web form for requesting these transfers and I have to enter in all the files that need to be uploaded. Sometimes this is one or two, other times is in the dozens.
So... I have a button that will flatten the view and filter it to display anything modified today (and isn't a wretched lock file). I then use that to transfer the contents tot he holding server. That part works slick and is impressive enough for my co-workers to consider getting DOpus. It's the next step: entering the list of files thus transfered that will now need to be uploaded. The above button works off the aforementioned flattened & filtered view and is supposed to copy the contents to the clipboard. This all works if I use the default Print Folder... button & specify the format, filter and destination. When I try to wrap that all up in a button, all I get is the whole blinkin' directory contents, which is very lengthy... :frowning:

I have to imagine that it's something simplistic that I'm messing up, but regardless, I would greatly appreciate any help with this! Thank you in advance!

How is the ModifiedTodayNoLocks filter defined?

Are the unwanted files only at the top-level or are they everywhere? (The manual says the filter is applied "when printing sub-folder contents" so it may not apply to things at the top level. Not sure if the manual means that literally, though.)

If you've already got the list of files you want in the lister, is there any reason not to copy the file names or file paths to the clipboard from that, rather than using the print-folder command?

Date Match Modified Within 1 day And Location No Match *\_* Use wildcards

The little monsters are shotgunned throughout and everywhere. They're really quite maddening.

Errr... because I somehow have completely spaced out and didn't know about the Clipboard command? Am reading up on that now... (slinking away, feeling rather dumb...)

That filter looks okay to me so, unless someone else here can spot anything wrong with what you were doing, it might be worth filing a bug report (even if the other method I suggested works better anyway).

Well, after playing around with Clipboard, I regrettably report that it will not suffice, or at least not in the ideal. I can either get filenames sans path or filenames with complete path. What I need is filenames with path from the lister's current location. E.g., if the lister is on C:\Server\Users\Me\Data\ and there are files both at that level as well as in sub-directories, I'd like the output to be along the lines of:

As it stands, even the Print Files... options aren't perfect since I still have to strip out the white space left by the path column. Sigh...

So - I definitely think this is a general bug in the Print FOLDER function. It actually doesn't look like the FILTER specified as an argument is being applied at all...

FWIW - "what" you're trying to do works fine if you manually punch the info into the Print FOLDER "dialog" (i.e. without the QUIET arg)

As a sort of KLUDGE, what you [i]could[/i] do is set up all the criteria you want the print folder operation to run by in the dialog "manually", and then save the /dopuslocaldata\State Data\printfolder.osd file generated as a result 'somewhere' else on your hard drive as a sort of 'print folder dialog template file since that is where Opus saves the last used settings for the print folder function... Then create a button which copies that file BACK to the /dopuslocaldata\State Data folder before running the Print FOLDER function. It means you have to click the OK button after the dialog pops up... but it "works".

And incidentally, providing all the information such as you have withOUT the QUIET arg is something I'd have expected the Print FOLDER dialog to use to pre-populate itself with the 'other' stuff you're specifying as arguments... i.e. the output type as text / csv, etc... I'd even expect the FORMAT criteria to be "applied" to the dialog instance even though the dialog itself doesn't have an explicit way of 'selecting' a custom format from the list of saved Favorite Formats...

As an aside - based on your very last comment - I'm assuming that you're desired "Names Only" folder format actually includes the "Location (relative)" field as the first column before the filename. If not, add it... and consider changing your clipboard output type to "Tab Separated" (which also doesn't seem to be available as a command line / function argument), and then at least you can perhaps right a script to to a find/replace of the character with a backslash instead...? At least that way - you've got a static string (the TAB char) to use to strip out that "space" between the relative path and the filename to end up with what I think you're looking for to fill into the web applet...

At any rate - I think there are some bug reports to file here. I think all of the options specified for the Print function need to work with Print FOLDER and the QUIET arg... and I'd really like to think GPSoft can make those same options 'pre-populate' the dialog if used withOUT the QUIET arg... Also, as another aside - it seems the header/footer option seems to not do anything these days?

I hate to resurrect this issue, but even after the update that listed this problem as having been fixed, I still have the problem! This morning - the first time I've had any spare time to address this issue in the past six months or so - I discovered that the button works fine if the QUIET option is omitted. Not the ideal way since I'm so incredibly lazy (being a government worker means I'm grossly overpaid and lazy to boot: standard dictionary definition I've been told), but there you have it.

Thank you!

Best thing to do is report it to GPSoftware. Maybe the QUIET arg was overlooked when the fix was done (or the fix was for some other problem) and it needs looking at again.

(I assume the fix you mean is "The FILTER argument for the Print FOLDER command now works correctly" from