On Jul 17, 4:32 pm, "Todd Vargo" <tlva...@sbcglobal.netz> wrote:
> happytoday wrote:
> > I need to automate those 2 tasks :
> > 1-Distribute number of files inside 1 directory to subdirectories
> > created each one include only 1000 file. All of them named
> > 1,2,3...etc.
> > 2-compare names of files inside 2 directories and see the different of
> > files .
> > Please help .
> > Thanks in advance .
>
> We will be glad to HELP you. So that we are not doing all of your work for
> you, show us what you have written so far.
>
> --
> Todd Vargo
> (Post questions to group only. Remove "z" to email personal messages)
Well - I know where you're coming from, but my biggest problem is that
the problems are pretty loosely defined - maybe an English as a second
(or third) language issue.
The second one is pretty easy to write, but hard to imagine for a less
than intermediate batch writer, so I took a crack (using NT/2K/XP/
Vista(?) approach) ...
@echo off
set fldr1="D:\Folder 1"
set fldr2="X:\Folder 2"
for %%A in (%fldr1%\*.*) do (
if not exist %fldr2%\%%~nxA (
echo %%~nxA in %fldr1% and NOT in %fldr2%)
)
)
for %%A in (%fldr2%\*.*) do (
if not exist %fldr1%\%%~nxA (
echo %%~nxA in %fldr2% and NOT in %fldr1%)
)
)
This can be done in no NT variant OSs, need to forgo the use of the
parentheses and CD into the folder under test before each of the FOR
statements. If the folders are on different drive it requires another
trick or two. But I leave that to a follow up (if there is one).
I didn't touch the first one without OPs input (code and or more
explanation of what is trying to be accomplished.)
Tom Lavedas
===========
http://members.cox.net/tglbatch/wsh/