Amiga.org
Amiga computer related discussion => Amiga Software Issues and Discussion => Topic started by: robo-ant on January 31, 2009, 05:17:01 AM
-
Hi,
I want to be able to drag files onto an AmiDock icon and have an AmigaDOS script executed with the dragged file's filename as an argument.
Can it be done?
I have tried making the icon type "Tool", and I have tried making it a "Project" icon and using iconx. Both of these run the script but it doesn't get the filename.
I'm running AmigaOS 3.9.
Thanks.
-
Does your script work if you run it from the shell and pass the parameters manually? E.g.:
execute myscript hd0:myfile
Also, have you tried a very simple script, something like this:
.key myvar
.bra {
.ket }
echo {myvar}
--
moto
-
motorollin wrote:
.bra {
.ket }
Hey, this is not the quantum physics forum!
:-P
-
Does your script work if you run it from the shell and pass the parameters manually?
Yes, it does. It also works if I click on the file, and then double-click on the script's icon on Workbench.
I would rather not have this icon on Workbench, but on AmiDock, where I could just drop files onto it.
Maybe SnoopDOS will be my friend.
-
OK, I have it working now.
What fixed it was changing the "Start from:" setting in the icon from "Shell" to "Workbench".
I don't know what the difference actually is, but it has solved the problem.