Batch Move - Undesired warning msg

Brolon January 30, 2009 at 00:35:03
Specs: Windows XP
Hello everybody,

in a BAT file, I execute :

move %SRC% %DST%

If the source folder is empty, I received an undesired message :

"The filename, directory name or volume label syntax is incorrect".

Is there a mean to avoid this message to display ?

Thanks in advance.

Best regards.


See More: Batch Move - Undesired warning msg

Report •


#1
January 30, 2009 at 00:53:10
Try %SRC%\*.*


=====================================
If at first you don't succeed, you're about average.

M2


Report •

#2
January 30, 2009 at 02:16:30
Actually, that is already what I do.

Report •

#3
January 30, 2009 at 03:01:27
move "%SRC%" "%DST%"

Report •

Related Solutions

#4
January 30, 2009 at 04:36:08
I also tried this one, without success ...

Report •

#5
January 30, 2009 at 05:07:55
are %SRC% %DST% on different hard drives?

have you tried using quotes around them?

ie: "%SRC%" "%DST%"


Report •

#6
January 30, 2009 at 05:24:08
Yeah, they are on different Disks.

If I use xcopy, then del, it works properly.


Report •

#7
January 30, 2009 at 08:05:42
if exist "%SRC%\*" move "%SRC%\*" "%DST%"

Report •


Ask Question