97Views2Replies

Author Options:

Secret spy image photo copying batch file Answered

Good Afternoon All.

I am wondering if someone could assist me in tweaking an excellent batch file. Below is a line of code I wish to change:

for /f "tokens=* delims= " %%f in ('dir/b/s/a-d c:\*.%%a') do (

What I would like to do is have the file back up images from the current user profile rather than the entire Hard Drive. I have tried the following combinations with no success:

for /f "tokens=* delims= " %%f in ('dir/b/s/a-d %USERPROFILE%\*.%%a') do (

set location=%USERPROFILE%

for /f "tokens=* delims= " %%f in ('dir/b/s/a-d %location%\*.%%a') do (

for /f "tokens=* delims= " %%f in (%USERPROFILE%\*.%%a') do (

I would be very greatful for any assistance.

Regards,
Daniel

2 Replies

user
یاسرم (author)2016-03-10


I am wondering if someone could assist me in tweaking an excellent batch file. Below is a line of code I wish to change:

for /f "tokens=* delims= " %%f in ('dir/b/s/a-d c:\*.%%a') do (

What I would like to do is have the file back up images from the current user profile rather than the entire Hard Drive. I have tried the following combinations with no success:

for /f "tokens=* delims= " %%f in ('dir/b/s/a-d %USERPROFILE%\*.%%a') do (

set location=%USERPROFILE%

for /f "tokens=* delims= " %%f in ('dir/b/s/a-d %location%\*.%%a') do (

for /f "tokens=* delims= " %%f in (%USERPROFILE%\*.%%a') do (

I would be very greatful for any assistance.

Regards,
Daniel

Select as Best AnswerUndo Best Answer

user
Kiteman (author)2009-08-24