ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

DonationCoder.com Software > Drag&Drop Robot

Folders in Drag and Drop??

(1/2) > >>

springro:
Hi,

This might be a simple one that I'm just not getting.

I have a script that normally I just put into the directory where I need it to run kick it off.  It cycles through the files needed.

I'm having trouble finding a way to drop folders onto DDR that would then just run the script in each folder.

I thinked I worked around this before by dropping a file from a folder and just ignoring it's value - but there was only 1.  Here there are multiple folders, not as elegant to have to drag a file from each folder.

Thanks,
Rob

mouser:
d+d is very happy to have folders dropped on it and to process folders, you just have to make sure you've checked the right option on the far right.



ps.
I actually have an updated version of D+D robot that i need to upload, with better support for running scripts and stuff (old version complained if you tried to run a non exe/bat script like perl, etc.)

springro:

I see that feature, but what I need it to do is to basically CD to each of the directories that are dropped, not use the directory as a parameter.

I even tried:

cd %P;C:\Scripts\Bb\fixes_drapdroprobot.bat   (which then just simply launches fixes.vbs

(and then cd %A - which seemed better, but didn't work either).  The script is programmed to run only on the directory it's in, so it didn't like the cd method.

Does that make sense?  I'm still missing something?

Thanks again,
Rob

mouser:
i understand what you are trying to do;
here is my memory and 2 possible solutions.

1) i think you might be able to do:
cd C:\Scripts\Bb\fixes_drapdroprobot.bat

which basically SHOULD mean, switch to the dropped folder directory and then run the script.


2) a cleaner more general solution would simply be to make a batch file or script which looks like:
cd "%1"
run C:\Scripts\Bb\fixes_drapdroprobot.bat

something like that.

in other words, d+d isnt great at running built in shell commands, so instead put them in a bat file and run the bat file, and let the bat file do the cd.

springro:

 :Thmbsup: #2 worked great. 

Thanks again.

Navigation

[0] Message Index

[#] Next page

Go to full version