Page 1 of 1

Support for SELECTFILES "*.%S:~-0,-255"

Posted: 2023-05-13, 00:12 UTC
by petermad
Currently this button works when different file names are selected:

Code: Select all

TOTALCMD#BAR#DATA
SELECTFILESS
"%S:~-0,255.*"
wcmicons.dll,39
Select all items with same base names as selected items - hold Shift down to also select folders
But this one does not work if more than one file type is selected:

Code: Select all

TOTALCMD#BAR#DATA
SELECTFILESS
"*.%S:~-0,-255"
wcmicons.dll,39
Select all items with same extensions as selected items - hold Shift down to also select folders
Is there a chance that %S could be made to work with a prefix for multiple file types.

Re: Support for SELECTFILES "*.%S:~-0,-255"

Posted: 2023-08-23, 12:04 UTC
by petermad
In TC 11.01rci we got this:
history.txt wrote:09.08.23 Added: Button bar, start menu, parameters field: Better handling of parameters %S, %R, %P%S and %T%R in double quotes with appended text: "%Sbeforeext%Eafterext" inserts string beforeext before extension, and string afterext after. Supports env vars in the form %|variablename| (32/64)
It would still be nice if appending strings before name could also be supported, so a contruction like "*.%S:~-0,-255" would work.

Re: Support for SELECTFILES "*.%S:~-0,-255"

Posted: 2023-08-24, 08:42 UTC
by ghisler(Author)
That would indeed by nice to have, but would require extensive changes to the parameter parser - it currently just parses from left to right.