Page 1 of 1

Arguments are overriden when using Drag&Drop

Posted: 2022-Apr-22, 11:29 am
by gue11
Hello, I'm Gunter.

Hope, that someone in this forum can help me:

In my VB script I use arguments that specify target paths for copying files. As an example: A link from my script has the arguments /dest:"c:\out c:\in". This means that files should be copied to these two directories.

But now I want to use the script with Drag&Drop as well. When I drag a file onto the link, my arguments are overridden with the filename.

Does anyone know, how I can keep both, the dropped filename and the arguments of the link?

Thank you and best regards
Gunter

Re: Arguments are overriden when using Drag&Drop

Posted: 2022-Apr-22, 9:03 pm
by Simon Sheppard
My first thought would be to add a batch file, drag a file onto the batch file,which then calls the VBScript using cscript.exe passing whatever arguments you want, which could include %* for the dropped filename(s).