From: Jonathan Zaldivar on
I would like to know if someone can explain to me what the script do becasue
the way understand it parses from a text file or copying from a template
user in AD . Thank you in advance for shedding some light on the script.

if exist %temp%\!%uid%*.txt del %temp%\!%uid%*.txt


set from_dsn=CN=_netcour_Template,OU=Not People,DC=netcour,DC=com

for /f "delims=" %%i in ('dsget user "%from_dsn%" -memberof -s NCS18') do
@dsmod group %%i -s NCS18 -addmbr "%usr_dsn%" 1>>%temp%\!%uid%.txt
2>>%temp%\!%uid%e.txt


From: contrex on
On 30 Jan, 02:42, "Jonathan Zaldivar" <jczaldiv...(a)verizon.net> wrote:

> if exist %temp%\!%uid%*.txt del %temp%\!%uid%*.txt
>
> set from_dsn=CN=_netcour_Template,OU=Not People,DC=netcour,DC=com
>
> for /f "delims=" %%i in ('dsget user "%from_dsn%" -memberof -s NCS18') do
> @dsmod group %%i -s NCS18 -addmbr "%usr_dsn%" 1>>%temp%\!%uid%.txt
> 2>>%temp%\!%uid%e.txt

It does not parse from a text file. It parses the output of the dsget
command and feeds it to the dsmod cmmand and redirects the console
stderr output to a log file.

This is an NT family command script, not VBS at all. You can type
dsget and dsmod at the prompt to see the help for these commands. Post
in alt.msdos.batch.nt if you need help understanding the command
script features.