I created a batchfile that creates a folder and copies a file in it.
I have to run it like this : makenotes jdoe
Then it creates a folder on server called jdoe and copies a file in it.
if I have 10 users i have to perform this action 10 times.
the code is :
Code: Select all
if not exist \\server\Home\%1 goto :noads
if exist \\server\Notesprofiles\%1 goto :exist
goto proceed
:exist
echo.
echo Notes Profile Folder already exists!
echo.
goto end
:noads
echo.
echo No ADS-Homefolder found!
echo.
goto :end
:proceed
echo.
echo Creating Notesprofile Directory...
md \\server\Notesprofiles\%1
echo Copying Notes INI-File...
copy \\server\Notesprofiles\000_sample_notes_data_folder\Lotus_Notes_80x_on_English_OS\notes.ini \\Maa-fs-01\server\%1
echo Adjusting permissions of the Notesprofile Directory...
cacls \\server\%1 /e /t /g %1:c
cacls \\server\%1 /e /t /g %1:r
cacls \\server\%1 /e /t /g %1:w
echo Done.
echo.
:end
I want to have a situation that :
If I create a textfile where I place all usernames.
My batchfiles reads this textfile and does the same as the above script.
so textfile is :
I can get these usernames in the textfile from an excel sheet, so just copy paste.
jdoe
jan
bla
and my batchfile reads this textfile and does what the above batch does.
I can get these usernames in the textfile from an excel sheet, so just copy paste.