After reading this for several times, it seems to me as if you're better of doing it with a separate script or something. I actually don't get where the list of random file names comes from. Could that be generated maybe, is it even necessary? Additionally, I don't get how you determine the number of files to copy from that list. And then, how do you do the required selection in the file display to finally run RFC? Maybe a separate short snippet, which runs upfront to read the file and copy some items from there to the clip is a start/an option.
That said, I think I won't add support for input from files here. This command is deprecated, there is RenameEx (did not upload recent version it seems or still need to merge what I have prepared here, oops! o). Additionally, I thought about a method to streamline script in/output of items, because the "source" question comes up again and again. You want items from file, the next buddy from destination display, someone else likes to pass items by commandline and for me, I might prefer to pass item names by a DO vector for increased script interoperability. So, instead of adding support for the various in/output buckets each time - implemented differently in the worst case (parameter names e.g.), it seems there should be an universal approach, which can be put in place and "done". Making requests like this the past. I've started on that thing already and use it in a script addin not published yet (TFS source control). It's a matter of time (or big money! o), when things will enhance and move on from there into other script commands.
Note that the randomfile list is already available. A simple .txt file with many random names.
As said, right now I open that list and clipboard copy a part of the list, which I hope will be sufficient, and then use RenameFromClipboard.
My idea was to use data from a list, instead of from clipboard, so the 'steps' of opening/clipboard copy would not be necessary anymore.
Just an idea though.
I just discovered there is something similar to what I suggested: 'From file rename script version 3.1' (from gieron).
Gave it a try.
Drawbacks (for me, that is):
-the 'source' filelist with random names should always be placed in the folder with the files to be renamed first
(so it requires me to first find the file with random names and then copy it to the respective folder - i.e. browsing thru folders,
click, click.. it would be better to have the file list in the Opus directory by default)
-it does not support files that are displayed when using Set FLATVIEW=Toggle,MixedNoFolders
Sounds like a very specific and (odd? o) usecase but why not. It's not related to renaming things, so something like this won't make it into this addin or its followup (which I need to upload someday). Cannot remember your scripting capabilities, but modifying this one to do what you imagine shouldn't be too hard.
Indeed, very specific, long story and not really interesting for others.
Just now found a workaround though, 3rd party software.
So forget it.
btw: my scripting capabilities are nil...
Just a very minor tip tbone, the latest is 0.3, on the 1st page 0.2.2 is said to be the latest. The one listed above 'latest' is actually indeed the latest, i.e. v0.3.
My button doesn't work anymore
When I use the button it tries to remove the file name and only leave the ".{ext}" and stops after the first file because it's trying to make a file with the same name.
You can avoid that problem by using %item.new_name% instead, and adding IGNOREEXT to tell Opus to preserve the file extension instead of the script having to do it:
(The old FILEINFO switch was also removed as it isn't needed in Opus 12 or above.)
Thank you
It's good to know that is built in as well.. I have avoided using the built in rename thing in the past because Bulk Rename Utility usually does what I want and I don't know how to script.
@Twilight
Please go with Leos suggestions or add actual file extensions to your file names in the clipboard, I think that's the cause of the problem. Not saying that there isn't something to be fixed here. o)
I'm not 100% sure now that that was the same button.. My C drive died recently and I stupidly had the configuration backup on the same drive. If that command does only work if the extensions are there that could make sense. Currently I'm copying folder names and putting them on files.. It's possible I only used that button when I was copying names from one set of files to another before. So there might not be anything to fix but I don't know.
I do think it was the same button though because I think it came with the theme (or whatever it's called) I'm using.
Yep, I obviously missed that, but to my defense, I updated and wrote the correct version at 3 other locations at least! o) Now updated inner-script as well, thank you! o)
Is anyone having trouble with this script? It doesn't work for me anymore. When I select a batch of files and run RenameFromClipboard, it opens the rename window with only the first of the selected files and doesn't bring the clipboard names in.