I'm looking to automate the process of adding users. I'm going to be faced
with 40-50 laptops that need to be completely updated and the users of each
laptop re-added.

Ideally, the script would work something like this:

-input box prompts me for the username to be added
-upon receiving the username the script checks an Excel worksheet
-contained in the Excel worksheet is the username in question, as well as
the other necessary info (full name, description, password) in accompanying
cells
-based on the username the script finds in the Excel worksheet, it takes the
accompanying cells with the additional information needed and fills it in
accordingly (ie. username contained in A1, takes Full Name found in B1, the
Description found in C1, and so on)

Is something like this even possible without getting too involved/complex?

Any help would be appreciated.
--
Never looking back...or too far in front of me; the present is a gift - and
I just wanna BE.

Re: VBS and Excel interaction? by Richard

Richard
Thu May 17 11:47:36 CDT 2007

2poor wrote:

> I'm looking to automate the process of adding users. I'm going to be
> faced
> with 40-50 laptops that need to be completely updated and the users of
> each
> laptop re-added.
>
> Ideally, the script would work something like this:
>
> -input box prompts me for the username to be added
> -upon receiving the username the script checks an Excel worksheet
> -contained in the Excel worksheet is the username in question, as well as
> the other necessary info (full name, description, password) in
> accompanying
> cells
> -based on the username the script finds in the Excel worksheet, it takes
> the
> accompanying cells with the additional information needed and fills it in
> accordingly (ie. username contained in A1, takes Full Name found in B1,
> the
> Description found in C1, and so on)
>
> Is something like this even possible without getting too involved/complex?

If these are domain users to be added to AD, just add them in bulk all at
once. I have a sample VBScript program that does this based on the
information in an Excel spreadsheet linked here:

http://www.rlmueller.net/CreateUsers.htm

If these are local users on each computer, then a script to add the users
must use the WinNT provider (instead of the LDAP provider). The spreadsheet
must be accessible to all, which implies the machines are joined to the
domain. I don't think that is what you intend, however.

--
Richard Mueller
Microsoft MVP Scripting and ADSI
Hilltop Lab - http://www.rlmueller.net
--