Click or drag to resize

UserInfoCreateLocalUser Method

Creates a new local user if it does not exist already.

Namespace: GSF.Identity
Assembly: GSF.Core (in GSF.Core.dll) Version: 2.4.232-beta+203aa83a5a82d50f387e69875549969ad138d6e0
Syntax
public static bool CreateLocalUser(
	string userName,
	string password,
	string userDescription = null
)
View Source

Parameters

userName  String
User name to create if it doesn't exist.
password  String
Password to user for new user.
userDescription  String  (Optional)
Optional user description.

Return Value

Boolean
true if user was created; otherwise, false if user already existed.
Exceptions
ExceptionCondition
ArgumentNullExceptionuserName or password was null.
ArgumentExceptionNo userName was specified.
InvalidOperationExceptionCould not create local user.
See Also