Sign in with
Sign up | Sign in
Your question

Deploying user list to workgroup

Tags:
  • Microsoft
  • Windows
Last response: in Windows 2000/NT
Share
Anonymous
April 5, 2005 2:23:02 AM

Archived from groups: microsoft.public.win2000.general (More info?)

This should be easy but I am stumped.

How do I deploy, or copy, 150 user names to a 23 computer workgroup so I
don't have to make 3,450 entries? 20 computers are 2K/SP4 and three are
XP/SP2. All are on the same workgroup.

Thanks,

Tom

More about : deploying user list workgroup

April 5, 2005 6:01:02 AM

Archived from groups: microsoft.public.win2000.general (More info?)

okay, i wrote you a script that will do this for you.

requirements:
- admin account on all workstations has same username/password (if not
you'll have to run it locally from each machine)
-must be able to resolve names of workstations
-adds users to Power Users group, change to desired group if Power Users is
wrong (search the code for Power Users and replace with group name you want)
- on 1 workstation create the file members.txt located at c:\members.txt
(this contains the names of all workstations you want the users added to - 1
name per line)
- on the same workstation create the text file users.txt located at
c:\users.txt (contains user accounts & their passwords - the format must be
user,password 1 per line and no space after the comma unless you want
the password to start with a space.
- on the same workstation create the text file enjoy.txt open it and past
the following code inside then save as "enjoy.vbs" with the quotes
- Double click enjoy.vbs and come back later - a message will alert you when
its done.

'START COPY

On error resume next

Set WSHShell = WScript.CreateObject("WScript.Shell")
Set objFSO = CreateObject("Scripting.FileSystemObject")

members = "c:\members.txt"
users = "c:\users.txt"

Const ForReading = 1

strInputFile = members

Set objTextStream = objFSO.OpenTextFile(strInputFile, ForReading)
arrComputers = Split(objTextStream.ReadAll, vbCrLf)
objTextStream.Close

Set objTextFile = objFSO.OpenTextFile _
(users, ForReading)

For Each strComputer In arrComputers

Do Until objTextFile.AtEndOfStream
acctInfo = objTextFile.Readline

uP = Split(acctInfo, ",", -1, 1)

Set colAccounts = GetObject("WinNT://" & strComputer & "")
Set objUser = colAccounts.Create("user", uP(0))
objUser.SetPassword uP(1)
objUser.SetInfo

Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
objGroup.Add(objUseraDD.ADsPath)


Loop

Next

wscript.echo "Accounts have been created"

wscript.quit
'END COPY

Hope this helps.

Nick


"Goatbiker" wrote:

> This should be easy but I am stumped.
>
> How do I deploy, or copy, 150 user names to a 23 computer workgroup so I
> don't have to make 3,450 entries? 20 computers are 2K/SP4 and three are
> XP/SP2. All are on the same workgroup.
>
> Thanks,
>
> Tom
Anonymous
April 5, 2005 11:09:07 AM

Archived from groups: microsoft.public.win2000.general (More info?)

Thanks Nick. This will be a big help.

"Nick" wrote:

> okay, i wrote you a script that will do this for you.
>
> requirements:
> - admin account on all workstations has same username/password (if not
> you'll have to run it locally from each machine)
> -must be able to resolve names of workstations
> -adds users to Power Users group, change to desired group if Power Users is
> wrong (search the code for Power Users and replace with group name you want)
> - on 1 workstation create the file members.txt located at c:\members.txt
> (this contains the names of all workstations you want the users added to - 1
> name per line)
> - on the same workstation create the text file users.txt located at
> c:\users.txt (contains user accounts & their passwords - the format must be
> user,password 1 per line and no space after the comma unless you want
> the password to start with a space.
> - on the same workstation create the text file enjoy.txt open it and past
> the following code inside then save as "enjoy.vbs" with the quotes
> - Double click enjoy.vbs and come back later - a message will alert you when
> its done.
>
> 'START COPY
>
> On error resume next
>
> Set WSHShell = WScript.CreateObject("WScript.Shell")
> Set objFSO = CreateObject("Scripting.FileSystemObject")
>
> members = "c:\members.txt"
> users = "c:\users.txt"
>
> Const ForReading = 1
>
> strInputFile = members
>
> Set objTextStream = objFSO.OpenTextFile(strInputFile, ForReading)
> arrComputers = Split(objTextStream.ReadAll, vbCrLf)
> objTextStream.Close
>
> Set objTextFile = objFSO.OpenTextFile _
> (users, ForReading)
>
> For Each strComputer In arrComputers
>
> Do Until objTextFile.AtEndOfStream
> acctInfo = objTextFile.Readline
>
> uP = Split(acctInfo, ",", -1, 1)
>
> Set colAccounts = GetObject("WinNT://" & strComputer & "")
> Set objUser = colAccounts.Create("user", uP(0))
> objUser.SetPassword uP(1)
> objUser.SetInfo
>
> Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
> Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
> objGroup.Add(objUseraDD.ADsPath)
>
>
> Loop
>
> Next
>
> wscript.echo "Accounts have been created"
>
> wscript.quit
> 'END COPY
>
> Hope this helps.
>
> Nick
>
>
> "Goatbiker" wrote:
>
> > This should be easy but I am stumped.
> >
> > How do I deploy, or copy, 150 user names to a 23 computer workgroup so I
> > don't have to make 3,450 entries? 20 computers are 2K/SP4 and three are
> > XP/SP2. All are on the same workgroup.
> >
> > Thanks,
> >
> > Tom
Related resources
Anonymous
April 5, 2005 1:45:05 PM

Archived from groups: microsoft.public.win2000.general (More info?)

Nick,

No Joy. Did as instructed, script runs and says "accounts have been
created", but no accounts on computers. It will not deploy and it will not
install the user to the computer it is on. Any thoughts?

Tom

"Nick" wrote:

> okay, i wrote you a script that will do this for you.
>
> requirements:
> - admin account on all workstations has same username/password (if not
> you'll have to run it locally from each machine)
> -must be able to resolve names of workstations
> -adds users to Power Users group, change to desired group if Power Users is
> wrong (search the code for Power Users and replace with group name you want)
> - on 1 workstation create the file members.txt located at c:\members.txt
> (this contains the names of all workstations you want the users added to - 1
> name per line)
> - on the same workstation create the text file users.txt located at
> c:\users.txt (contains user accounts & their passwords - the format must be
> user,password 1 per line and no space after the comma unless you want
> the password to start with a space.
> - on the same workstation create the text file enjoy.txt open it and past
> the following code inside then save as "enjoy.vbs" with the quotes
> - Double click enjoy.vbs and come back later - a message will alert you when
> its done.
>
> 'START COPY
>
> On error resume next
>
> Set WSHShell = WScript.CreateObject("WScript.Shell")
> Set objFSO = CreateObject("Scripting.FileSystemObject")
>
> members = "c:\members.txt"
> users = "c:\users.txt"
>
> Const ForReading = 1
>
> strInputFile = members
>
> Set objTextStream = objFSO.OpenTextFile(strInputFile, ForReading)
> arrComputers = Split(objTextStream.ReadAll, vbCrLf)
> objTextStream.Close
>
> Set objTextFile = objFSO.OpenTextFile _
> (users, ForReading)
>
> For Each strComputer In arrComputers
>
> Do Until objTextFile.AtEndOfStream
> acctInfo = objTextFile.Readline
>
> uP = Split(acctInfo, ",", -1, 1)
>
> Set colAccounts = GetObject("WinNT://" & strComputer & "")
> Set objUser = colAccounts.Create("user", uP(0))
> objUser.SetPassword uP(1)
> objUser.SetInfo
>
> Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
> Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
> objGroup.Add(objUseraDD.ADsPath)
>
>
> Loop
>
> Next
>
> wscript.echo "Accounts have been created"
>
> wscript.quit
> 'END COPY
>
> Hope this helps.
>
> Nick
>
>
> "Goatbiker" wrote:
>
> > This should be easy but I am stumped.
> >
> > How do I deploy, or copy, 150 user names to a 23 computer workgroup so I
> > don't have to make 3,450 entries? 20 computers are 2K/SP4 and three are
> > XP/SP2. All are on the same workgroup.
> >
> > Thanks,
> >
> > Tom
Anonymous
April 5, 2005 6:19:49 PM

Archived from groups: microsoft.public.win2000.general (More info?)

Goatbiker wrote:
> This should be easy but I am stumped.
>
> How do I deploy, or copy, 150 user names to a 23 computer workgroup
> so I don't have to make 3,450 entries? 20 computers are 2K/SP4 and
> three are XP/SP2. All are on the same workgroup.
>
> Thanks,
>
> Tom

OT, but my oh my, why do you have a workgroup if you have 23 computers? You
must be a glutton for punishment! More than a handful of computers, and
workgroups aren't the best choice - not scalable, a pain in the ___ to
administer, secure, control, back up, etc..... I strongly suggest that you
install a server in there and create a domain. Look into SBS2003 for a very
nice affordable package....

My head hurts just thinking about your question. :) 
Anonymous
April 5, 2005 6:21:03 PM

Archived from groups: microsoft.public.win2000.general (More info?)

Lanwench,

What can I say. Schools do what schools do. I have to work with what I have.

Tom

"Lanwench [MVP - Exchange]" wrote:

> Goatbiker wrote:
> > This should be easy but I am stumped.
> >
> > How do I deploy, or copy, 150 user names to a 23 computer workgroup
> > so I don't have to make 3,450 entries? 20 computers are 2K/SP4 and
> > three are XP/SP2. All are on the same workgroup.
> >
> > Thanks,
> >
> > Tom
>
> OT, but my oh my, why do you have a workgroup if you have 23 computers? You
> must be a glutton for punishment! More than a handful of computers, and
> workgroups aren't the best choice - not scalable, a pain in the ___ to
> administer, secure, control, back up, etc..... I strongly suggest that you
> install a server in there and create a domain. Look into SBS2003 for a very
> nice affordable package....
>
> My head hurts just thinking about your question. :) 
>
>
>
Anonymous
April 6, 2005 12:21:02 AM

Archived from groups: microsoft.public.win2000.general (More info?)

Tom-

I retested the script and it worked fine for me, unfortunately I guess that
doesn't really matter since the goal is to get it working for you ;) 

Do you have any XP boxes where you're at? I'm guessing the reason it's
working for me and not for you is I ran it on an XP box and possibly some of
the code is not supported when run from 2000. If you want to verify this,
open the script in notepad and put an appostrophe before the line on error
resume next (should be like the first or second line in the script. Save it
and then try running it - I bet you get an error (the on error resume next
line basically supresses errors and the appostrophe comments out the line so
you can see what's really going on).

If my guess is right, then I think the script will still be able to update
the 2000 boxes but it might just need to be run via windows xp. Would that
be feasable or is there no way you can get a box set up with XP (if not I'll
try to modify the script but I don't have a 2k box to test it on so it'll be
a bit tricky).

Please let me know, thanks.

Nick

"Goatbiker" wrote:

> Nick,
>
> No Joy. Did as instructed, script runs and says "accounts have been
> created", but no accounts on computers. It will not deploy and it will not
> install the user to the computer it is on. Any thoughts?
>
> Tom
>
> "Nick" wrote:
>
> > okay, i wrote you a script that will do this for you.
> >
> > requirements:
> > - admin account on all workstations has same username/password (if not
> > you'll have to run it locally from each machine)
> > -must be able to resolve names of workstations
> > -adds users to Power Users group, change to desired group if Power Users is
> > wrong (search the code for Power Users and replace with group name you want)
> > - on 1 workstation create the file members.txt located at c:\members.txt
> > (this contains the names of all workstations you want the users added to - 1
> > name per line)
> > - on the same workstation create the text file users.txt located at
> > c:\users.txt (contains user accounts & their passwords - the format must be
> > user,password 1 per line and no space after the comma unless you want
> > the password to start with a space.
> > - on the same workstation create the text file enjoy.txt open it and past
> > the following code inside then save as "enjoy.vbs" with the quotes
> > - Double click enjoy.vbs and come back later - a message will alert you when
> > its done.
> >
> > 'START COPY
> >
> > On error resume next
> >
> > Set WSHShell = WScript.CreateObject("WScript.Shell")
> > Set objFSO = CreateObject("Scripting.FileSystemObject")
> >
> > members = "c:\members.txt"
> > users = "c:\users.txt"
> >
> > Const ForReading = 1
> >
> > strInputFile = members
> >
> > Set objTextStream = objFSO.OpenTextFile(strInputFile, ForReading)
> > arrComputers = Split(objTextStream.ReadAll, vbCrLf)
> > objTextStream.Close
> >
> > Set objTextFile = objFSO.OpenTextFile _
> > (users, ForReading)
> >
> > For Each strComputer In arrComputers
> >
> > Do Until objTextFile.AtEndOfStream
> > acctInfo = objTextFile.Readline
> >
> > uP = Split(acctInfo, ",", -1, 1)
> >
> > Set colAccounts = GetObject("WinNT://" & strComputer & "")
> > Set objUser = colAccounts.Create("user", uP(0))
> > objUser.SetPassword uP(1)
> > objUser.SetInfo
> >
> > Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
> > Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
> > objGroup.Add(objUseraDD.ADsPath)
> >
> >
> > Loop
> >
> > Next
> >
> > wscript.echo "Accounts have been created"
> >
> > wscript.quit
> > 'END COPY
> >
> > Hope this helps.
> >
> > Nick
> >
> >
> > "Goatbiker" wrote:
> >
> > > This should be easy but I am stumped.
> > >
> > > How do I deploy, or copy, 150 user names to a 23 computer workgroup so I
> > > don't have to make 3,450 entries? 20 computers are 2K/SP4 and three are
> > > XP/SP2. All are on the same workgroup.
> > >
> > > Thanks,
> > >
> > > Tom
Anonymous
April 6, 2005 3:25:07 AM

Archived from groups: microsoft.public.win2000.general (More info?)

Nick,

That could be it. When I took the XPs off the list it deployed to the 2Ks.
I am on my way for now. Tomorrow, I'll try your fix to see what it tells
us. Thanks again.

Tom




"Nick Staff" wrote:

> Tom-
>
> I retested the script and it worked fine for me, unfortunately I guess that
> doesn't really matter since the goal is to get it working for you ;) 
>
> Do you have any XP boxes where you're at? I'm guessing the reason it's
> working for me and not for you is I ran it on an XP box and possibly some of
> the code is not supported when run from 2000. If you want to verify this,
> open the script in notepad and put an appostrophe before the line on error
> resume next (should be like the first or second line in the script. Save it
> and then try running it - I bet you get an error (the on error resume next
> line basically supresses errors and the appostrophe comments out the line so
> you can see what's really going on).
>
> If my guess is right, then I think the script will still be able to update
> the 2000 boxes but it might just need to be run via windows xp. Would that
> be feasable or is there no way you can get a box set up with XP (if not I'll
> try to modify the script but I don't have a 2k box to test it on so it'll be
> a bit tricky).
>
> Please let me know, thanks.
>
> Nick
>
> "Goatbiker" wrote:
>
> > Nick,
> >
> > No Joy. Did as instructed, script runs and says "accounts have been
> > created", but no accounts on computers. It will not deploy and it will not
> > install the user to the computer it is on. Any thoughts?
> >
> > Tom
> >
> > "Nick" wrote:
> >
> > > okay, i wrote you a script that will do this for you.
> > >
> > > requirements:
> > > - admin account on all workstations has same username/password (if not
> > > you'll have to run it locally from each machine)
> > > -must be able to resolve names of workstations
> > > -adds users to Power Users group, change to desired group if Power Users is
> > > wrong (search the code for Power Users and replace with group name you want)
> > > - on 1 workstation create the file members.txt located at c:\members.txt
> > > (this contains the names of all workstations you want the users added to - 1
> > > name per line)
> > > - on the same workstation create the text file users.txt located at
> > > c:\users.txt (contains user accounts & their passwords - the format must be
> > > user,password 1 per line and no space after the comma unless you want
> > > the password to start with a space.
> > > - on the same workstation create the text file enjoy.txt open it and past
> > > the following code inside then save as "enjoy.vbs" with the quotes
> > > - Double click enjoy.vbs and come back later - a message will alert you when
> > > its done.
> > >
> > > 'START COPY
> > >
> > > On error resume next
> > >
> > > Set WSHShell = WScript.CreateObject("WScript.Shell")
> > > Set objFSO = CreateObject("Scripting.FileSystemObject")
> > >
> > > members = "c:\members.txt"
> > > users = "c:\users.txt"
> > >
> > > Const ForReading = 1
> > >
> > > strInputFile = members
> > >
> > > Set objTextStream = objFSO.OpenTextFile(strInputFile, ForReading)
> > > arrComputers = Split(objTextStream.ReadAll, vbCrLf)
> > > objTextStream.Close
> > >
> > > Set objTextFile = objFSO.OpenTextFile _
> > > (users, ForReading)
> > >
> > > For Each strComputer In arrComputers
> > >
> > > Do Until objTextFile.AtEndOfStream
> > > acctInfo = objTextFile.Readline
> > >
> > > uP = Split(acctInfo, ",", -1, 1)
> > >
> > > Set colAccounts = GetObject("WinNT://" & strComputer & "")
> > > Set objUser = colAccounts.Create("user", uP(0))
> > > objUser.SetPassword uP(1)
> > > objUser.SetInfo
> > >
> > > Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
> > > Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
> > > objGroup.Add(objUseraDD.ADsPath)
> > >
> > >
> > > Loop
> > >
> > > Next
> > >
> > > wscript.echo "Accounts have been created"
> > >
> > > wscript.quit
> > > 'END COPY
> > >
> > > Hope this helps.
> > >
> > > Nick
> > >
> > >
> > > "Goatbiker" wrote:
> > >
> > > > This should be easy but I am stumped.
> > > >
> > > > How do I deploy, or copy, 150 user names to a 23 computer workgroup so I
> > > > don't have to make 3,450 entries? 20 computers are 2K/SP4 and three are
> > > > XP/SP2. All are on the same workgroup.
> > > >
> > > > Thanks,
> > > >
> > > > Tom
Anonymous
April 7, 2005 1:01:02 AM

Archived from groups: microsoft.public.win2000.general (More info?)

Nick,

I'll try to stop bothering you with this, but I can only deploy to one
computer at a time, no matter how many are on the members list. Each
computer name (the network ID) is on a seperate line. Any clues?

Tom

"Nick Staff" wrote:

> Tom-
>
> I retested the script and it worked fine for me, unfortunately I guess that
> doesn't really matter since the goal is to get it working for you ;) 
>
> Do you have any XP boxes where you're at? I'm guessing the reason it's
> working for me and not for you is I ran it on an XP box and possibly some of
> the code is not supported when run from 2000. If you want to verify this,
> open the script in notepad and put an appostrophe before the line on error
> resume next (should be like the first or second line in the script. Save it
> and then try running it - I bet you get an error (the on error resume next
> line basically supresses errors and the appostrophe comments out the line so
> you can see what's really going on).
>
> If my guess is right, then I think the script will still be able to update
> the 2000 boxes but it might just need to be run via windows xp. Would that
> be feasable or is there no way you can get a box set up with XP (if not I'll
> try to modify the script but I don't have a 2k box to test it on so it'll be
> a bit tricky).
>
> Please let me know, thanks.
>
> Nick
>
> "Goatbiker" wrote:
>
> > Nick,
> >
> > No Joy. Did as instructed, script runs and says "accounts have been
> > created", but no accounts on computers. It will not deploy and it will not
> > install the user to the computer it is on. Any thoughts?
> >
> > Tom
> >
> > "Nick" wrote:
> >
> > > okay, i wrote you a script that will do this for you.
> > >
> > > requirements:
> > > - admin account on all workstations has same username/password (if not
> > > you'll have to run it locally from each machine)
> > > -must be able to resolve names of workstations
> > > -adds users to Power Users group, change to desired group if Power Users is
> > > wrong (search the code for Power Users and replace with group name you want)
> > > - on 1 workstation create the file members.txt located at c:\members.txt
> > > (this contains the names of all workstations you want the users added to - 1
> > > name per line)
> > > - on the same workstation create the text file users.txt located at
> > > c:\users.txt (contains user accounts & their passwords - the format must be
> > > user,password 1 per line and no space after the comma unless you want
> > > the password to start with a space.
> > > - on the same workstation create the text file enjoy.txt open it and past
> > > the following code inside then save as "enjoy.vbs" with the quotes
> > > - Double click enjoy.vbs and come back later - a message will alert you when
> > > its done.
> > >
> > > 'START COPY
> > >
> > > On error resume next
> > >
> > > Set WSHShell = WScript.CreateObject("WScript.Shell")
> > > Set objFSO = CreateObject("Scripting.FileSystemObject")
> > >
> > > members = "c:\members.txt"
> > > users = "c:\users.txt"
> > >
> > > Const ForReading = 1
> > >
> > > strInputFile = members
> > >
> > > Set objTextStream = objFSO.OpenTextFile(strInputFile, ForReading)
> > > arrComputers = Split(objTextStream.ReadAll, vbCrLf)
> > > objTextStream.Close
> > >
> > > Set objTextFile = objFSO.OpenTextFile _
> > > (users, ForReading)
> > >
> > > For Each strComputer In arrComputers
> > >
> > > Do Until objTextFile.AtEndOfStream
> > > acctInfo = objTextFile.Readline
> > >
> > > uP = Split(acctInfo, ",", -1, 1)
> > >
> > > Set colAccounts = GetObject("WinNT://" & strComputer & "")
> > > Set objUser = colAccounts.Create("user", uP(0))
> > > objUser.SetPassword uP(1)
> > > objUser.SetInfo
> > >
> > > Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
> > > Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
> > > objGroup.Add(objUseraDD.ADsPath)
> > >
> > >
> > > Loop
> > >
> > > Next
> > >
> > > wscript.echo "Accounts have been created"
> > >
> > > wscript.quit
> > > 'END COPY
> > >
> > > Hope this helps.
> > >
> > > Nick
> > >
> > >
> > > "Goatbiker" wrote:
> > >
> > > > This should be easy but I am stumped.
> > > >
> > > > How do I deploy, or copy, 150 user names to a 23 computer workgroup so I
> > > > don't have to make 3,450 entries? 20 computers are 2K/SP4 and three are
> > > > XP/SP2. All are on the same workgroup.
> > > >
> > > > Thanks,
> > > >
> > > > Tom
Anonymous
April 7, 2005 4:13:05 AM

Archived from groups: microsoft.public.win2000.general (More info?)

Tom-

You are not bothering me in the least - if anything it's my fault for giving
you code that doesn't work right. I don't know why I did this, but when I
initially tested the script I didn't use multiple computer names, I just
tested the local machine then ran it again for a remote machine. After your
post tonight I tried using multiple machines in the members.txt and it didn't
work for me either. I have made the neccesary changes though and now it
works. Here is the new code:

On error resume next

Set WSHShell = WScript.CreateObject("WScript.Shell")
Set objFSO = CreateObject("Scripting.FileSystemObject")

members = "c:\members.txt"
users = "c:\users.txt"

Const ForReading = 1

Set objMembers = objFSO.OpenTextFile _
(members, ForReading)

Do Until objMembers.AtEndOfStream
StrComputer = objmembers.Readline

Set objTextFile = objFSO.OpenTextFile _
(users, ForReading)

Do Until objTextFile.AtEndOfStream
acctInfo = objTextFile.Readline

uP = Split(acctInfo, ",", -1, 1)

Set colAccounts = GetObject("WinNT://" & strComputer & "")
Set objUser = colAccounts.Create("user", uP(0))
objUser.SetPassword uP(1)
objUser.SetInfo

Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
objGroup.Add(objUseraDD.ADsPath)

Loop

Loop

wscript.echo "Accounts have been created"

wscript.quit

"Goatbiker" wrote:

> Nick,
>
> I'll try to stop bothering you with this, but I can only deploy to one
> computer at a time, no matter how many are on the members list. Each
> computer name (the network ID) is on a seperate line. Any clues?
>
> Tom
>
> "Nick Staff" wrote:
>
> > Tom-
> >
> > I retested the script and it worked fine for me, unfortunately I guess that
> > doesn't really matter since the goal is to get it working for you ;) 
> >
> > Do you have any XP boxes where you're at? I'm guessing the reason it's
> > working for me and not for you is I ran it on an XP box and possibly some of
> > the code is not supported when run from 2000. If you want to verify this,
> > open the script in notepad and put an appostrophe before the line on error
> > resume next (should be like the first or second line in the script. Save it
> > and then try running it - I bet you get an error (the on error resume next
> > line basically supresses errors and the appostrophe comments out the line so
> > you can see what's really going on).
> >
> > If my guess is right, then I think the script will still be able to update
> > the 2000 boxes but it might just need to be run via windows xp. Would that
> > be feasable or is there no way you can get a box set up with XP (if not I'll
> > try to modify the script but I don't have a 2k box to test it on so it'll be
> > a bit tricky).
> >
> > Please let me know, thanks.
> >
> > Nick
> >
> > "Goatbiker" wrote:
> >
> > > Nick,
> > >
> > > No Joy. Did as instructed, script runs and says "accounts have been
> > > created", but no accounts on computers. It will not deploy and it will not
> > > install the user to the computer it is on. Any thoughts?
> > >
> > > Tom
> > >
> > > "Nick" wrote:
> > >
> > > > okay, i wrote you a script that will do this for you.
> > > >
> > > > requirements:
> > > > - admin account on all workstations has same username/password (if not
> > > > you'll have to run it locally from each machine)
> > > > -must be able to resolve names of workstations
> > > > -adds users to Power Users group, change to desired group if Power Users is
> > > > wrong (search the code for Power Users and replace with group name you want)
> > > > - on 1 workstation create the file members.txt located at c:\members.txt
> > > > (this contains the names of all workstations you want the users added to - 1
> > > > name per line)
> > > > - on the same workstation create the text file users.txt located at
> > > > c:\users.txt (contains user accounts & their passwords - the format must be
> > > > user,password 1 per line and no space after the comma unless you want
> > > > the password to start with a space.
> > > > - on the same workstation create the text file enjoy.txt open it and past
> > > > the following code inside then save as "enjoy.vbs" with the quotes
> > > > - Double click enjoy.vbs and come back later - a message will alert you when
> > > > its done.
> > > >
> > > > 'START COPY
> > > >
> > > > On error resume next
> > > >
> > > > Set WSHShell = WScript.CreateObject("WScript.Shell")
> > > > Set objFSO = CreateObject("Scripting.FileSystemObject")
> > > >
> > > > members = "c:\members.txt"
> > > > users = "c:\users.txt"
> > > >
> > > > Const ForReading = 1
> > > >
> > > > strInputFile = members
> > > >
> > > > Set objTextStream = objFSO.OpenTextFile(strInputFile, ForReading)
> > > > arrComputers = Split(objTextStream.ReadAll, vbCrLf)
> > > > objTextStream.Close
> > > >
> > > > Set objTextFile = objFSO.OpenTextFile _
> > > > (users, ForReading)
> > > >
> > > > For Each strComputer In arrComputers
> > > >
> > > > Do Until objTextFile.AtEndOfStream
> > > > acctInfo = objTextFile.Readline
> > > >
> > > > uP = Split(acctInfo, ",", -1, 1)
> > > >
> > > > Set colAccounts = GetObject("WinNT://" & strComputer & "")
> > > > Set objUser = colAccounts.Create("user", uP(0))
> > > > objUser.SetPassword uP(1)
> > > > objUser.SetInfo
> > > >
> > > > Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
> > > > Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
> > > > objGroup.Add(objUseraDD.ADsPath)
> > > >
> > > >
> > > > Loop
> > > >
> > > > Next
> > > >
> > > > wscript.echo "Accounts have been created"
> > > >
> > > > wscript.quit
> > > > 'END COPY
> > > >
> > > > Hope this helps.
> > > >
> > > > Nick
> > > >
> > > >
> > > > "Goatbiker" wrote:
> > > >
> > > > > This should be easy but I am stumped.
> > > > >
> > > > > How do I deploy, or copy, 150 user names to a 23 computer workgroup so I
> > > > > don't have to make 3,450 entries? 20 computers are 2K/SP4 and three are
> > > > > XP/SP2. All are on the same workgroup.
> > > > >
> > > > > Thanks,
> > > > >
> > > > > Tom
Anonymous
April 7, 2005 12:57:07 PM

Archived from groups: microsoft.public.win2000.general (More info?)

Pure Joy! Works like a charm.

Thank You,

Tom

"Nick Staff" wrote:

> Tom-
>
> You are not bothering me in the least - if anything it's my fault for giving
> you code that doesn't work right. I don't know why I did this, but when I
> initially tested the script I didn't use multiple computer names, I just
> tested the local machine then ran it again for a remote machine. After your
> post tonight I tried using multiple machines in the members.txt and it didn't
> work for me either. I have made the neccesary changes though and now it
> works. Here is the new code:
>
> On error resume next
>
> Set WSHShell = WScript.CreateObject("WScript.Shell")
> Set objFSO = CreateObject("Scripting.FileSystemObject")
>
> members = "c:\members.txt"
> users = "c:\users.txt"
>
> Const ForReading = 1
>
> Set objMembers = objFSO.OpenTextFile _
> (members, ForReading)
>
> Do Until objMembers.AtEndOfStream
> StrComputer = objmembers.Readline
>
> Set objTextFile = objFSO.OpenTextFile _
> (users, ForReading)
>
> Do Until objTextFile.AtEndOfStream
> acctInfo = objTextFile.Readline
>
> uP = Split(acctInfo, ",", -1, 1)
>
> Set colAccounts = GetObject("WinNT://" & strComputer & "")
> Set objUser = colAccounts.Create("user", uP(0))
> objUser.SetPassword uP(1)
> objUser.SetInfo
>
> Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
> Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
> objGroup.Add(objUseraDD.ADsPath)
>
> Loop
>
> Loop
>
> wscript.echo "Accounts have been created"
>
> wscript.quit
>
> "Goatbiker" wrote:
>
> > Nick,
> >
> > I'll try to stop bothering you with this, but I can only deploy to one
> > computer at a time, no matter how many are on the members list. Each
> > computer name (the network ID) is on a seperate line. Any clues?
> >
> > Tom
> >
> > "Nick Staff" wrote:
> >
> > > Tom-
> > >
> > > I retested the script and it worked fine for me, unfortunately I guess that
> > > doesn't really matter since the goal is to get it working for you ;) 
> > >
> > > Do you have any XP boxes where you're at? I'm guessing the reason it's
> > > working for me and not for you is I ran it on an XP box and possibly some of
> > > the code is not supported when run from 2000. If you want to verify this,
> > > open the script in notepad and put an appostrophe before the line on error
> > > resume next (should be like the first or second line in the script. Save it
> > > and then try running it - I bet you get an error (the on error resume next
> > > line basically supresses errors and the appostrophe comments out the line so
> > > you can see what's really going on).
> > >
> > > If my guess is right, then I think the script will still be able to update
> > > the 2000 boxes but it might just need to be run via windows xp. Would that
> > > be feasable or is there no way you can get a box set up with XP (if not I'll
> > > try to modify the script but I don't have a 2k box to test it on so it'll be
> > > a bit tricky).
> > >
> > > Please let me know, thanks.
> > >
> > > Nick
> > >
> > > "Goatbiker" wrote:
> > >
> > > > Nick,
> > > >
> > > > No Joy. Did as instructed, script runs and says "accounts have been
> > > > created", but no accounts on computers. It will not deploy and it will not
> > > > install the user to the computer it is on. Any thoughts?
> > > >
> > > > Tom
> > > >
> > > > "Nick" wrote:
> > > >
> > > > > okay, i wrote you a script that will do this for you.
> > > > >
> > > > > requirements:
> > > > > - admin account on all workstations has same username/password (if not
> > > > > you'll have to run it locally from each machine)
> > > > > -must be able to resolve names of workstations
> > > > > -adds users to Power Users group, change to desired group if Power Users is
> > > > > wrong (search the code for Power Users and replace with group name you want)
> > > > > - on 1 workstation create the file members.txt located at c:\members.txt
> > > > > (this contains the names of all workstations you want the users added to - 1
> > > > > name per line)
> > > > > - on the same workstation create the text file users.txt located at
> > > > > c:\users.txt (contains user accounts & their passwords - the format must be
> > > > > user,password 1 per line and no space after the comma unless you want
> > > > > the password to start with a space.
> > > > > - on the same workstation create the text file enjoy.txt open it and past
> > > > > the following code inside then save as "enjoy.vbs" with the quotes
> > > > > - Double click enjoy.vbs and come back later - a message will alert you when
> > > > > its done.
> > > > >
> > > > > 'START COPY
> > > > >
> > > > > On error resume next
> > > > >
> > > > > Set WSHShell = WScript.CreateObject("WScript.Shell")
> > > > > Set objFSO = CreateObject("Scripting.FileSystemObject")
> > > > >
> > > > > members = "c:\members.txt"
> > > > > users = "c:\users.txt"
> > > > >
> > > > > Const ForReading = 1
> > > > >
> > > > > strInputFile = members
> > > > >
> > > > > Set objTextStream = objFSO.OpenTextFile(strInputFile, ForReading)
> > > > > arrComputers = Split(objTextStream.ReadAll, vbCrLf)
> > > > > objTextStream.Close
> > > > >
> > > > > Set objTextFile = objFSO.OpenTextFile _
> > > > > (users, ForReading)
> > > > >
> > > > > For Each strComputer In arrComputers
> > > > >
> > > > > Do Until objTextFile.AtEndOfStream
> > > > > acctInfo = objTextFile.Readline
> > > > >
> > > > > uP = Split(acctInfo, ",", -1, 1)
> > > > >
> > > > > Set colAccounts = GetObject("WinNT://" & strComputer & "")
> > > > > Set objUser = colAccounts.Create("user", uP(0))
> > > > > objUser.SetPassword uP(1)
> > > > > objUser.SetInfo
> > > > >
> > > > > Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
> > > > > Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
> > > > > objGroup.Add(objUseraDD.ADsPath)
> > > > >
> > > > >
> > > > > Loop
> > > > >
> > > > > Next
> > > > >
> > > > > wscript.echo "Accounts have been created"
> > > > >
> > > > > wscript.quit
> > > > > 'END COPY
> > > > >
> > > > > Hope this helps.
> > > > >
> > > > > Nick
> > > > >
> > > > >
> > > > > "Goatbiker" wrote:
> > > > >
> > > > > > This should be easy but I am stumped.
> > > > > >
> > > > > > How do I deploy, or copy, 150 user names to a 23 computer workgroup so I
> > > > > > don't have to make 3,450 entries? 20 computers are 2K/SP4 and three are
> > > > > > XP/SP2. All are on the same workgroup.
> > > > > >
> > > > > > Thanks,
> > > > > >
> > > > > > Tom
Anonymous
April 7, 2005 3:55:03 PM

Archived from groups: microsoft.public.win2000.general (More info?)

Excellent, I'm very happy - thanks for letting me know!

"Goatbiker" wrote:

> Pure Joy! Works like a charm.
>
> Thank You,
>
> Tom
>
> "Nick Staff" wrote:
>
> > Tom-
> >
> > You are not bothering me in the least - if anything it's my fault for giving
> > you code that doesn't work right. I don't know why I did this, but when I
> > initially tested the script I didn't use multiple computer names, I just
> > tested the local machine then ran it again for a remote machine. After your
> > post tonight I tried using multiple machines in the members.txt and it didn't
> > work for me either. I have made the neccesary changes though and now it
> > works. Here is the new code:
> >
> > On error resume next
> >
> > Set WSHShell = WScript.CreateObject("WScript.Shell")
> > Set objFSO = CreateObject("Scripting.FileSystemObject")
> >
> > members = "c:\members.txt"
> > users = "c:\users.txt"
> >
> > Const ForReading = 1
> >
> > Set objMembers = objFSO.OpenTextFile _
> > (members, ForReading)
> >
> > Do Until objMembers.AtEndOfStream
> > StrComputer = objmembers.Readline
> >
> > Set objTextFile = objFSO.OpenTextFile _
> > (users, ForReading)
> >
> > Do Until objTextFile.AtEndOfStream
> > acctInfo = objTextFile.Readline
> >
> > uP = Split(acctInfo, ",", -1, 1)
> >
> > Set colAccounts = GetObject("WinNT://" & strComputer & "")
> > Set objUser = colAccounts.Create("user", uP(0))
> > objUser.SetPassword uP(1)
> > objUser.SetInfo
> >
> > Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
> > Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
> > objGroup.Add(objUseraDD.ADsPath)
> >
> > Loop
> >
> > Loop
> >
> > wscript.echo "Accounts have been created"
> >
> > wscript.quit
> >
> > "Goatbiker" wrote:
> >
> > > Nick,
> > >
> > > I'll try to stop bothering you with this, but I can only deploy to one
> > > computer at a time, no matter how many are on the members list. Each
> > > computer name (the network ID) is on a seperate line. Any clues?
> > >
> > > Tom
> > >
> > > "Nick Staff" wrote:
> > >
> > > > Tom-
> > > >
> > > > I retested the script and it worked fine for me, unfortunately I guess that
> > > > doesn't really matter since the goal is to get it working for you ;) 
> > > >
> > > > Do you have any XP boxes where you're at? I'm guessing the reason it's
> > > > working for me and not for you is I ran it on an XP box and possibly some of
> > > > the code is not supported when run from 2000. If you want to verify this,
> > > > open the script in notepad and put an appostrophe before the line on error
> > > > resume next (should be like the first or second line in the script. Save it
> > > > and then try running it - I bet you get an error (the on error resume next
> > > > line basically supresses errors and the appostrophe comments out the line so
> > > > you can see what's really going on).
> > > >
> > > > If my guess is right, then I think the script will still be able to update
> > > > the 2000 boxes but it might just need to be run via windows xp. Would that
> > > > be feasable or is there no way you can get a box set up with XP (if not I'll
> > > > try to modify the script but I don't have a 2k box to test it on so it'll be
> > > > a bit tricky).
> > > >
> > > > Please let me know, thanks.
> > > >
> > > > Nick
> > > >
> > > > "Goatbiker" wrote:
> > > >
> > > > > Nick,
> > > > >
> > > > > No Joy. Did as instructed, script runs and says "accounts have been
> > > > > created", but no accounts on computers. It will not deploy and it will not
> > > > > install the user to the computer it is on. Any thoughts?
> > > > >
> > > > > Tom
> > > > >
> > > > > "Nick" wrote:
> > > > >
> > > > > > okay, i wrote you a script that will do this for you.
> > > > > >
> > > > > > requirements:
> > > > > > - admin account on all workstations has same username/password (if not
> > > > > > you'll have to run it locally from each machine)
> > > > > > -must be able to resolve names of workstations
> > > > > > -adds users to Power Users group, change to desired group if Power Users is
> > > > > > wrong (search the code for Power Users and replace with group name you want)
> > > > > > - on 1 workstation create the file members.txt located at c:\members.txt
> > > > > > (this contains the names of all workstations you want the users added to - 1
> > > > > > name per line)
> > > > > > - on the same workstation create the text file users.txt located at
> > > > > > c:\users.txt (contains user accounts & their passwords - the format must be
> > > > > > user,password 1 per line and no space after the comma unless you want
> > > > > > the password to start with a space.
> > > > > > - on the same workstation create the text file enjoy.txt open it and past
> > > > > > the following code inside then save as "enjoy.vbs" with the quotes
> > > > > > - Double click enjoy.vbs and come back later - a message will alert you when
> > > > > > its done.
> > > > > >
> > > > > > 'START COPY
> > > > > >
> > > > > > On error resume next
> > > > > >
> > > > > > Set WSHShell = WScript.CreateObject("WScript.Shell")
> > > > > > Set objFSO = CreateObject("Scripting.FileSystemObject")
> > > > > >
> > > > > > members = "c:\members.txt"
> > > > > > users = "c:\users.txt"
> > > > > >
> > > > > > Const ForReading = 1
> > > > > >
> > > > > > strInputFile = members
> > > > > >
> > > > > > Set objTextStream = objFSO.OpenTextFile(strInputFile, ForReading)
> > > > > > arrComputers = Split(objTextStream.ReadAll, vbCrLf)
> > > > > > objTextStream.Close
> > > > > >
> > > > > > Set objTextFile = objFSO.OpenTextFile _
> > > > > > (users, ForReading)
> > > > > >
> > > > > > For Each strComputer In arrComputers
> > > > > >
> > > > > > Do Until objTextFile.AtEndOfStream
> > > > > > acctInfo = objTextFile.Readline
> > > > > >
> > > > > > uP = Split(acctInfo, ",", -1, 1)
> > > > > >
> > > > > > Set colAccounts = GetObject("WinNT://" & strComputer & "")
> > > > > > Set objUser = colAccounts.Create("user", uP(0))
> > > > > > objUser.SetPassword uP(1)
> > > > > > objUser.SetInfo
> > > > > >
> > > > > > Set objGroup = GetObject("WinNT://" & strComputer & "/Power Users,group")
> > > > > > Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
> > > > > > objGroup.Add(objUseraDD.ADsPath)
> > > > > >
> > > > > >
> > > > > > Loop
> > > > > >
> > > > > > Next
> > > > > >
> > > > > > wscript.echo "Accounts have been created"
> > > > > >
> > > > > > wscript.quit
> > > > > > 'END COPY
> > > > > >
> > > > > > Hope this helps.
> > > > > >
> > > > > > Nick
> > > > > >
> > > > > >
> > > > > > "Goatbiker" wrote:
> > > > > >
> > > > > > > This should be easy but I am stumped.
> > > > > > >
> > > > > > > How do I deploy, or copy, 150 user names to a 23 computer workgroup so I
> > > > > > > don't have to make 3,450 entries? 20 computers are 2K/SP4 and three are
> > > > > > > XP/SP2. All are on the same workgroup.
> > > > > > >
> > > > > > > Thanks,
> > > > > > >
> > > > > > > Tom
Anonymous
April 29, 2005 11:15:23 AM

Archived from groups: microsoft.public.win2000.general (More info?)

This is really incredible. Goatbiker, I feel your pain, and I've been
looking for a solution to this problem (the 25 computer, 25 user
workgroup problem). I will upgrade to a domain as soon as possible,
but right now this script is going to have to do the trick. I have one
question/request. I know we're supressing the errors and that if a
user is already created it just skips past them. Would it possible to
have it change their password to the updated password before it does
so? If it could do that, this script would just make my week,
literally.

P.S. - maybe it does that already and i'm wrong :)  i'm wrong quite
often.

Thanks for the help Nick.

-pk
Anonymous
April 29, 2005 11:19:37 AM

Archived from groups: microsoft.public.win2000.general (More info?)

oh, and one more thing.

although i'm quite sure it's impossible to do this, could someone
knowledgable please verify? it's impossible to remove the old accounts
of people that don't work here anymore through this script, right?

Thanks again.

-pk
Anonymous
April 29, 2005 1:54:04 PM

Archived from groups: microsoft.public.win2000.general (More info?)

If you put all the old users in a text file, one username per line, I could
modify the script to remove the accounts. Also I will do the mod to change
the PW if the account already exists and post it when done (should be today,
but can't promise).

Glad this is helping you!

Nick Staff

Sometimes I do things so dumb that I have to wonder where I was when all of
it was happening.


"pk" wrote:

> oh, and one more thing.
>
> although i'm quite sure it's impossible to do this, could someone
> knowledgable please verify? it's impossible to remove the old accounts
> of people that don't work here anymore through this script, right?
>
> Thanks again.
>
> -pk
>
>
Anonymous
April 29, 2005 2:50:48 PM

Archived from groups: microsoft.public.win2000.general (More info?)

awesome. i'm extremely excited. there's no rush on it (just please
don't forget! :) ), because i won't be able to do anything until monday,
but i appreciate all of the help. as far as putting all of the old
users in another file....there are a lot of them and they're very
inconsistent across the network as far as which computers have which
ones. so this would have to be a script that would skip over ones that
didn't exist on that particular machine. if that's possible, then i'd
love to have it.

thanks again.

-pk
Anonymous
April 29, 2005 3:08:04 PM

Archived from groups: microsoft.public.win2000.general (More info?)

the script would try all the users in the file but would keep going if the
users weren't present. I'm working on it now...
--
Nick Staff

Either I want to be a better person than I am
or I am a better person than I want to be.


"pk" wrote:

> awesome. i'm extremely excited. there's no rush on it (just please
> don't forget! :) ), because i won't be able to do anything until monday,
> but i appreciate all of the help. as far as putting all of the old
> users in another file....there are a lot of them and they're very
> inconsistent across the network as far as which computers have which
> ones. so this would have to be a script that would skip over ones that
> didn't exist on that particular machine. if that's possible, then i'd
> love to have it.
>
> thanks again.
>
> -pk
>
>
Anonymous
April 29, 2005 7:02:01 PM

Archived from groups: microsoft.public.win2000.general (More info?)

I've pasted the script below with the requested modifications and some
general updates. The script should be pretty self explanitory when you run
it but if not let me know. Enjoy and thank you.

On error resume next

Set WSHShell = WScript.CreateObject("WScript.Shell")
Set objFSO = CreateObject("Scripting.FileSystemObject")

wscript.echo "In the next window select the file containing a list of
computers to modify. Format must be 1 Computer name per line."

Set objDialogm = CreateObject("UserAccounts.CommonDialog")
objDialogm.Filter = "All Files|*.*"
objDialogm.FilterIndex = 1
selMembers = objDialogm.ShowOpen

IF selMembers = 0 then
wscript.echo "No computers to modify, no reasons to continue."
wscript.quit
END IF

wscript.echo "In the next window select the file containing a list of users
to add. Format must be username,password (1 username,password pair per
line)."

Set objDialogu = CreateObject("UserAccounts.CommonDialog")
objDialogu.Filter = "All Files|*.*"
objDialogu.FilterIndex = 1
selUsers = objDialogu.ShowOpen

addU = 1
IF selUsers = 0 then
addU = 0
END IF

wscript.echo "In the next window select the file containing the list of
users to remove. Format must be 1 User name per line"

Set objDialogr = CreateObject("UserAccounts.CommonDialog")
objDialogr.Filter = "All Files|*.*"
objDialogr.FilterIndex = 1
selRemove = objDialogr.ShowOpen

remU = 1
IF selRemove = 0 then
remU = 0
END IF

IF addU = 0 then
IF remU = 0 then
wscript.echo "No Users given, No reasons to continue"
wscript.quit
END IF
END IF

members = objDialogm.FileName
users = objDialogu.FileName
remove = objDialogr.Filename

modGroup = inputbox("What group should the new account(s) be a member of
(Group must already exist on remote machines)? If left blank, accounts will
be members of Users group.", "Workgroup Account Creator")

IF modGroup = EMPTY then
modGroup = Users
END IF

Const ForReading = 1

Set objMembers = objFSO.OpenTextFile _
(members, ForReading)

Do Until objMembers.AtEndOfStream
StrComputer = objmembers.Readline

IF addU = 1 then

Set objTextFile = objFSO.OpenTextFile _
(users, ForReading)

Do Until objTextFile.AtEndOfStream
acctInfo = objTextFile.Readline

uP = Split(acctInfo, ",", -1, 1)

Set colAccounts = GetObject("WinNT://" & strComputer & "")
Set objUser = colAccounts.Create("user", uP(0))
objUser.SetPassword uP(1)
objUser.SetInfo

Set objGroup = GetObject("WinNT://" & strComputer & "/" & modGroup & ",group")
Set objUseraDD = GetObject("WinNT://" & strComputer & "/" & uP(0) & ",user")
objGroup.Add(objUseraDD.ADsPath)

Set objUserrP = GetObject("WinNT://" & strComputer & "/" & uP(0) & ", user")

objUserrP.SetPassword uP(1)
objUserrP.SetInfo

Loop

END IF

IF remU = 1 then

Set objTextFiler = objFSO.OpenTextFile _
(remove, ForReading)

Do Until objTextFiler.AtEndOfStream
remAccount = objTextFiler.Readline

Set objComputer = GetObject("WinNT://" & strComputer & "")
objComputer.Delete "user", remAccount

Loop

END IF

Loop

wscript.echo "Accounts have been created/removed"

wscript.quit

--
Nick Staff

Either I want to be a better person than I am
or I am a better person than I want to be.


"pk" wrote:

> oh, and one more thing.
>
> although i'm quite sure it's impossible to do this, could someone
> knowledgable please verify? it's impossible to remove the old accounts
> of people that don't work here anymore through this script, right?
>
> Thanks again.
>
> -pk
>
>
Anonymous
April 29, 2005 10:02:50 PM

Archived from groups: microsoft.public.win2000.general (More info?)

wonderful. i just got home from work and checked to see that you wrote
the longest script ever for me. i appreciate it and will try it out on
monday.

thanks

-pk
Anonymous
May 1, 2005 2:00:17 AM

Archived from groups: microsoft.public.win2000.general (More info?)

Trying to re-install Roxio 6.0 off the original disk. I install as the
adminitrator and I have closed down the network because I get an error message
that says Error 1334 the file
5572_ERASDUST.354272C8_8A55_4DF7_9B0E_1A65983F1C9Ecannot be installed because
the file cannot be found in the cabinet file 'Data.cab'. This could indicate a
network error, an error reading from the C... The rest is missing as it does
not fit in the dialog box.

Please help. This program has previously installed and is the original disk as
bought from a local supplier.

I do not know what opens and reads the cabinet file but I have had trouble,
largely caused by USB errors. I reinstalled and restored. I therefore think that
I have everything back to normal but apparently not so.

For your information, my stats are:
Win 2000, Pentium 4 2.4 Ghz
1 Gb memory,ADSL
200+200 GB disks partitioned C:D :E;as 7.81,80.84.97.65
F: G: as 88.65,97.66 for data
Borge Pedersen :-)
Perth, Australia
mailto:b_o_r_g_e@SPAMiinet.net.au
remove SPAM and underlines for email
Anonymous
May 1, 2005 2:00:18 AM

Archived from groups: microsoft.public.win2000.general (More info?)

I would make a folder in the root of c: and then try copying the contents of
the CD to that folder. Then try installing from the folder instead of CD.
Also I think Erasdust is a font file (in case you were wondering).

Good luck.
--
Nick Staff

Either I want to be a better person than I am
or I am a better person than I want to be.


"nesredep egrob" wrote:

> Trying to re-install Roxio 6.0 off the original disk. I install as the
> adminitrator and I have closed down the network because I get an error message
> that says Error 1334 the file
> 5572_ERASDUST.354272C8_8A55_4DF7_9B0E_1A65983F1C9Ecannot be installed because
> the file cannot be found in the cabinet file 'Data.cab'. This could indicate a
> network error, an error reading from the C... The rest is missing as it does
> not fit in the dialog box.
>
> Please help. This program has previously installed and is the original disk as
> bought from a local supplier.
>
> I do not know what opens and reads the cabinet file but I have had trouble,
> largely caused by USB errors. I reinstalled and restored. I therefore think that
> I have everything back to normal but apparently not so.
>
> For your information, my stats are:
> Win 2000, Pentium 4 2.4 Ghz
> 1 Gb memory,ADSL
> 200+200 GB disks partitioned C:D :E;as 7.81,80.84.97.65
> F: G: as 88.65,97.66 for data
> Borge Pedersen :-)
> Perth, Australia
> mailto:b_o_r_g_e@SPAMiinet.net.au
> remove SPAM and underlines for email
>
Anonymous
May 1, 2005 3:38:25 PM

Archived from groups: microsoft.public.win2000.general (More info?)

On Sat, 30 Apr 2005 22:00:17 +0800, nesredep egrob <Long. -31,48.21 Lat.
115,47.40> wrote:

>Trying to re-install Roxio 6.0 off the original disk. I install as the
>adminitrator and I have closed down the network because I get an error message
>that says Error 1334 the file
>5572_ERASDUST.354272C8_8A55_4DF7_9B0E_1A65983F1C9Ecannot be installed because
>the file cannot be found in the cabinet file 'Data.cab'. This could indicate a
>network error, an error reading from the C... The rest is missing as it does
>not fit in the dialog box.
>
>Please help. This program has previously installed and is the original disk as
>bought from a local supplier.
>
>I do not know what opens and reads the cabinet file but I have had trouble,
>largely caused by USB errors. I reinstalled and restored. I therefore think that
>I have everything back to normal but apparently not so.
>
>For your information, my stats are:
>Win 2000, Pentium 4 2.4 Ghz
>1 Gb memory,ADSL
>200+200 GB disks partitioned C:D :E;as 7.81,80.84.97.65
>F: G: as 88.65,97.66 for data
>Borge Pedersen :-)
>Perth, Australia
>mailto:b_o_r_g_e@SPAMiinet.net.au
>remove SPAM and underlines for email


Thanks for the help. I also had trouble copying to the C: drive. I then tried to
install the drivers for the Pixma IP 5000 and I got a similar fault, it also
recused to read the cab file. This was also a CD which previously worked.
Seems that the CD/R/RW had trouble. Some vigerous use of the Laser lens cleaner
and some compressed air brought things back to normal. Installations are now
complete.

For your information, my stats are:
Win 2000, Pentium 4 2.4 Ghz
1 Gb memory,ADSL
200+200 GB disks partitioned C:D :E;as 7.81,80.84.97.65
F: G: as 88.65,97.66 for data
Borge Pedersen :-)
Perth, Australia
mailto:b_o_r_g_e@SPAMiinet.net.au
remove SPAM and underlines for email
Anonymous
May 1, 2005 3:40:35 PM

Archived from groups: microsoft.public.win2000.general (More info?)

On Sat, 30 Apr 2005 09:22:02 -0700, "Nick Staff" <nick.staff@comcast.net> wrote:

>I would make a folder in the root of c: and then try copying the contents of
>the CD to that folder. Then try installing from the folder instead of CD.
>Also I think Erasdust is a font file (in case you were wondering).
>
>Good luck.


Thanks for the help. I also had trouble copying to the C: drive. I then tried to
install the drivers for the Pixma IP5000 and I got a similar fault, it also
refused to read the cab file. This was also a CD which previously worked.
Seems that the CD/R/RW had trouble. Some vigerous use of the Laser lens cleaner
program and some compressed air brought things back to normal. installations are
now complete.

For your information, my stats are:
Win 2000, Pentium 4 2.4 Ghz
1 Gb memory,ADSL
200+200 GB disks partitioned C:D :E;as 7.81,80.84.97.65
F: G: as 88.65,97.66 for data
Borge Pedersen :-)
Perth, Australia
mailto:b_o_r_g_e@SPAMiinet.net.au
remove SPAM and underlines for email
Anonymous
May 2, 2005 10:51:12 AM

Archived from groups: microsoft.public.win2000.general (More info?)

ugh. i'm getting a weird error. i've done research on the internet
about it, but most of those seem related to ASP pages. the error
number is 800A01AD and it seems to be particularly pesky. Perhaps it
has something to do with having and registering the correct .ocx files?
i haven't been able to fix it, but it comes at the line

Set objDialogm = CreateObject("UserAccounts.CommonDialog")

It seems that maybe this CommonDialog .ocx that I need is available
either through office 2003, which I don't have or i need to pay for a
license. is that right?

-pk
Anonymous
May 2, 2005 5:58:09 PM

Archived from groups: microsoft.public.win2000.general (More info?)

Nick, if you're there, perhaps you could help me rewrite it using
something like this?

-------
Set objShellAppm = CreateObject ("Shell.Application")

Set objMyComputer = objShellApp.NameSpace (&H11&) ' My Computer
constant
Set objFindFolder = objShellApp.BrowseForFolder (0, "Browse to the
desired file", 0)

objShellApp.Open objMyComputer ' Opens the My Computer dialog box

objShellApp.Open objFindFolder 'Opens the Browse for Folder dialog box

--------
This seems to work for me, but I'm not sure how to adapt it to my
script. Thanks.

-pk
Anonymous
May 3, 2005 12:26:04 AM

Archived from groups: microsoft.public.win2000.general (More info?)

I do believe (though I could be wrong of course) that this needs to be run
from an XP box and that should take care of the problem. If you've tried it
on XP and it didn't work or you don't have an XP machine then let me know and
I'll rewrite it.

Also, I work during the day so if you post a message to me please understand
I don't even check my personal email until after 8:00pm PST. Also after
11:00PM PST there's no guarantee I'll check any personal mail until 8:00pm
the next evening (or course there's no guaranteee about anything but I mean
this is my usual routine). Just letting you know so you understand.

--
Nick Staff

Either I want to be a better person than I am
or I am a better person than I want to be.


"pk" wrote:

> Nick, if you're there, perhaps you could help me rewrite it using
> something like this?
>
> -------
> Set objShellAppm = CreateObject ("Shell.Application")
>
> Set objMyComputer = objShellApp.NameSpace (&H11&) ' My Computer
> constant
> Set objFindFolder = objShellApp.BrowseForFolder (0, "Browse to the
> desired file", 0)
>
> objShellApp.Open objMyComputer ' Opens the My Computer dialog box
>
> objShellApp.Open objFindFolder 'Opens the Browse for Folder dialog box
>
> --------
> This seems to work for me, but I'm not sure how to adapt it to my
> script. Thanks.
>
> -pk
>
>
!