No biggie. But I don't see why the former would work and the latter would not, since the latter works like a charm as a button inside DOpus. To my understanding, dopusrt is nothing else but a tool for sending signals to DOpus to carry out its own internal commands – it doesn't affect or alter the command before reaching DOpus? If that's correct, then the latter example IS in fact the same as putting the command in a button?
Also /acmd and /cmd seems to make no difference in this particular case. I'm happy nonetheless, since I was able to accomplish what I wanted (to mark the newest file after recording system audio). Consider this question solved.
Although it's probably a minor quirk, this might be something to look into at some point?
It's probably not Opus causing that difference. Look at the AHK code you're running:
Run, <command line>
Looks like AHK is using the , character to separate arguments to its commands/functions. You're passing in an unquoted string as the command line for the Run command/function. It's going wrong when that command line includes a , character (DATE=both,newest). The problem probably lies there.
I don't know enough about AHK but I suspect you need to quote the arguments in some way.
(You should definitely also be quoting the dopusrt.exe path, since it contains spaces and will go haywire if something creates an exe or folder named C:\Programs.)
The , , in the middle is to leave an empty value for WorkingDir. Using the commas makes it abundantly clear to AHK what items are parameters and should mean you don't have to use quotes.
To pass parameters, add them immediately after the program or document name. If a parameter contains spaces, it is safest to enclose it in double quotes (even though it may work without them in some cases).
And:
If Target contains any commas, they must be escaped as shown three times in the following example: ...
(Since this is no longer about Opus, but how to use AHK, it'd be best to move to the AHK forum if you need more help.)