NT 4 User Accounts

  • Thread starter Thread starter Shaun
  • Start date Start date
S

Shaun

Anyone,

I am trying to programmatically change user accounts in
Windows NT 4. I am using Microsoft Visual Basic .NET
2003. The two things I am trying to do are as follows.

1. Set the User Cannot Change Password Checkbox.
2. Select the Account Disabled Checkbox.

Can anyone tell me how to do this?

Thanks
 
I am trying to programmatically change user accounts in
Windows NT 4. I am using Microsoft Visual Basic .NET
2003. The two things I am trying to do are as follows.

1. Set the User Cannot Change Password Checkbox.
2. Select the Account Disabled Checkbox.

Hmm, forgive me, but one might question why?

Nick.

--
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
"No matter. Whatever the outcome, you are changed."

Fergus - September 5th 2003
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
 
User Admin program maybe? Automated account creation and attribute setting?
Network Administration tool for network supervisors? Network Administration
tool for computer illiterates... the list goes on and on.

In response to his question, he may need to take a look at the Net* API's.

--
HTH,
-- Tom Spink, Über Geek

Please respond to the newsgroup,
so all can benefit

"Maybe it's a game called 'Punish the User'"


: > I am trying to programmatically change user accounts in
: > Windows NT 4. I am using Microsoft Visual Basic .NET
: > 2003. The two things I am trying to do are as follows.
: >
: > 1. Set the User Cannot Change Password Checkbox.
: > 2. Select the Account Disabled Checkbox.
:
: Hmm, forgive me, but one might question why?
:
: Nick.
:
: --
:
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
: "No matter. Whatever the outcome, you are changed."
:
: Fergus - September 5th 2003
:
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
:
:
 
I need to create a simple tool that can disable user
accounts and select the user cannot change password
checkbox by giving the tool a list of names in a text
file. The list will contain about 300 users a week for a
year. Originally, I was going to use vbscript, but the
folks that were going to use the vbscript were afraid of
messing something up. Anyways, clicking around in three
hundred user accounts a week just isn't cool.

A point in the right direction would be helpful. I got it
to work with active directory. I can't seem to get it to
work with NT.

Thanks
 
Check out the NetUserGetInfo and NetUserSetInfo API calls and the
USER_INFO_1008 structure.

I need to create a simple tool that can disable user
accounts and select the user cannot change password
checkbox by giving the tool a list of names in a text
file. The list will contain about 300 users a week for a
year. Originally, I was going to use vbscript, but the
folks that were going to use the vbscript were afraid of
messing something up. Anyways, clicking around in three
hundred user accounts a week just isn't cool.

A point in the right direction would be helpful. I got it
to work with active directory. I can't seem to get it to
work with NT.

Thanks
 
User Admin program maybe? Automated account creation and attribute
setting?
Network Administration tool for network supervisors? Network Administration
tool for computer illiterates... the list goes on and on.

Right, an application for fu*king accounts up too maybe? Who knows, who
knows...

Nick.

--
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
"No matter. Whatever the outcome, you are changed."

Fergus - September 5th 2003
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
 
¤ > User Admin program maybe? Automated account creation and attribute
¤ setting?
¤ > Network Administration tool for network supervisors? Network
¤ Administration
¤ > tool for computer illiterates... the list goes on and on.
¤
¤ Right, an application for fu*king accounts up too maybe? Who knows, who
¤ knows...

No need to act ignorant.

Requirements for these types of tools is not uncommon.


Paul ~~~ (e-mail address removed)
Microsoft MVP (Visual Basic)
 
No need to act ignorant.

Well thanks for the advice Mr Clement, I shall take your thoughts into mind.
Requirements for these types of tools is not uncommon.

Personally I am not bothered whether people ask for code to mess other
peoples systems up or not. But just recently someone was asking for "ideas"
on what they could do to play a joke on a work associate, I gave suggestions
and everyone else thought it was "bad", though he *only* wanted ideas.

Now when someone asks how you disable accounts via code I wouldn't have
thought that there would have been an influx of answers, as this is allot
more serious than playing a simple joke on a work associate. Personally I
couldn't, nor can I still see the point in making software to do this, so
no, I was not "acting ignorant", but thanks for your concern anyway.

Nick.

--
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
"No matter. Whatever the outcome, you are changed."

Fergus - September 5th 2003
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
 
¤ > No need to act ignorant.
¤
¤ Well thanks for the advice Mr Clement, I shall take your thoughts into mind.
¤
¤ > Requirements for these types of tools is not uncommon.
¤
¤ Personally I am not bothered whether people ask for code to mess other
¤ peoples systems up or not. But just recently someone was asking for "ideas"
¤ on what they could do to play a joke on a work associate, I gave suggestions
¤ and everyone else thought it was "bad", though he *only* wanted ideas.
¤
¤ Now when someone asks how you disable accounts via code I wouldn't have
¤ thought that there would have been an influx of answers, as this is allot
¤ more serious than playing a simple joke on a work associate. Personally I
¤ couldn't, nor can I still see the point in making software to do this, so
¤ no, I was not "acting ignorant", but thanks for your concern anyway.

Sometimes you need to provide access to your system to enable customers to manage their users that
work with your (typically web based) system. For obvious reasons you wouldn't necessarily want to
provide them with the standard set of tools. ;-)

Having an interface API (such as ADSI or System.DirectoryServices which will address the original
question) enables you to provide only those features required, thereby limiting the administrative
functionality that is actually available.


Paul ~~~ (e-mail address removed)
Microsoft MVP (Visual Basic)
 
Absolutely Agree. I've written many a network admin tool for non-technical
users to easily manage accounts and etc.

--
HTH,
-- Tom Spink, Über Geek

Please respond to the newsgroup,
so all can benefit

"Maybe it's a game called 'Punish the User'"


:
: ¤ > No need to act ignorant.
: ¤
: ¤ Well thanks for the advice Mr Clement, I shall take your thoughts into
mind.
: ¤
: ¤ > Requirements for these types of tools is not uncommon.
: ¤
: ¤ Personally I am not bothered whether people ask for code to mess other
: ¤ peoples systems up or not. But just recently someone was asking for
"ideas"
: ¤ on what they could do to play a joke on a work associate, I gave
suggestions
: ¤ and everyone else thought it was "bad", though he *only* wanted ideas.
: ¤
: ¤ Now when someone asks how you disable accounts via code I wouldn't have
: ¤ thought that there would have been an influx of answers, as this is
allot
: ¤ more serious than playing a simple joke on a work associate. Personally
I
: ¤ couldn't, nor can I still see the point in making software to do this,
so
: ¤ no, I was not "acting ignorant", but thanks for your concern anyway.
:
: Sometimes you need to provide access to your system to enable customers to
manage their users that
: work with your (typically web based) system. For obvious reasons you
wouldn't necessarily want to
: provide them with the standard set of tools. ;-)
:
: Having an interface API (such as ADSI or System.DirectoryServices which
will address the original
: question) enables you to provide only those features required, thereby
limiting the administrative
: functionality that is actually available.
:
:
: Paul ~~~ (e-mail address removed)
: Microsoft MVP (Visual Basic)
 
Back
Top