Alternative Usage of Net Commands in Windows XP

  
        The Net User command is a DOS command that must be run in MS-DOS mode under Windows XP, so first enter MS-DOS mode: select the sub-option "Command Prompt" of the "Accessories" option in the "Start" menu, or Enter "cmd.exe" in the "Run" option of the "Start" menu (shortcut key is Win+R) to enter MS-DOS mode. The following features are based on this mode.

Create a normal new user

Enter the following command at the MS-DOS prompt: "net user john 123 /add", press Enter. You can create a new user named "John" with a password of "123". The Add parameter indicates a new user.

worth noting: the user name can have up to 20 characters, the password can be up to 127 characters.

Create a user with limited login time

The following methods can be used to control the computer usage time. For example, you need to create a John user account with a password of "123", login privileges from 8:00 am to 10:00 pm Monday to Friday, and 7:00 pm to 9:00 pm on weekends.

1. 12-hour type the following command: "net user john 123 /add /times: monday-friday, 8 AM-10PM; saturday-sunday, 7 PM-9PM", the transport can be determined.

2. 24-hour type the following command: "net user john 123 /add /times: MF, 8: 00-22: 00; Sa-Su, 19: 00-21: 00", back The car is OK.

worth noting: Time added value is limited to 1 hour. For the Day value, the full name or abbreviation (ie, M, T, W, Th, F, Sa, Su) can be used. A 12 hour or 24 hour time representation can be used. For the 12 hour representation, please use AM, PM or A.M., P.M. The All value means that the user can always log in; a null value (blank) means that the user can never log in. Separate the date and time with a comma and separate the date and time units with a semicolon (for example, M, 4AM-5PM; T, 1PM-3PM). Do not use spaces when specifying time.

Further, PassWordchg: {yesno} parameter used to decide whether the user can change their own password, default set to Yes.

Limiting the user's usage time

Net User command can also use the parameter Expires:{{mm/dd/yyyy dd/mm/yyyy mmm,dd,yyyy} never} to make the user account based on The specified Date expires to qualify the user. The expiration date can be in the format [mm/dd/yyyy], [dd/mm/yyyy] or [mmm, dd, yyyy]. It depends on the country code. The user account expires at the beginning of the specified date. For month values, a number, full or three-letter abbreviation (ie, Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, Dec) can be used. For year values, you can use two or four digits; separate each part of the date with a comma and a slash; do not use spaces.

example: To define user account John to November 5, 2004 expiration, you can type the following command: "net user john /expires: Nov /5/2004", Enter can be determined.

View user information, modify existing user passwords and delete users

If you use without parameters, Net User will display a list of users on the computer, such as typing the following command: Net user", press Enter to display all users of the system.

If you type: "net user john", Enter the user information can be displayed John's.

If you type the command: "net user john 123456 /add", press Enter to confirm, forcibly change the password of the user John (John is an existing user) to 123456.

If you type the command: "net user john /delete", press Enter to delete the user John.

on usage Net User command on the introduction of so many, in fact, a lot of skills like this, we need to continue to explore, communicate with each other.

Copyright © Windows knowledge All Rights Reserved