Unique username routine

NPUser

Registered User.
Local time
Yesterday, 20:03
Joined
Jul 25, 2004
Messages
55
Hello,
I was wondering if you have one or have seen a routine to generate unique
username from first, middle and last names. Here is my requirement -
by default first initial and last name of a user is their username.
But if the expected or default username is already taken then if the
user have middle initial, then the username for this user would be
first initial, middle initial and lastname. If the user does not have
middle name then the username for the user would be first two letters
of first name and lastname and if that's already taken then first
three letters of first name and last name and so on.

Any help or pointer is greatly appriciated.
 
wouldn't you be better using a fixed length number, or alpha key? having different length usernames could cause trouble or confusion later on.
 
Last edited:
Derek-dc,
thats not the point.

All users already have fixed length ID_num which is unique. I am trying to generate new user name for new users automatically. Eventually, grab this unique username and create their Active Directory w/ mail enable account. I already have VB route that looks into a database table and creates users automatically based on the information in a table. Last part of this puzzle is to avoid VB script run into potential duplicate usernames when it create user accounts in Active Directory.

sa
 

Users who are viewing this thread

Back
Top Bottom