RemoveUser Method (AUsers)

Removes a User.

Syntax

[ bVerified = ] Object.RemoveUser( varUserKey )

The RemoveUser method syntax has the following parts:

 

Name

Type

Description

Object

AUsers

AUsers object

varUserKey

Val Variant

An integer specifying the index of the current user in the list of users.

bVerified

Bool

A boolean expression that specifies whether the user was removed.

Where

bVerified can be one of the following:

 

Value

Description

True *

The user was removed.

False

The user was not removed.

Comments

This procedure will fail if no such key found in the list of users. In an AUsers object, there must be at least one system administrator account at all times. Thus this procedure also fails if the specified user is the only system administrator.

Example

The following example will remove the user:

if users.RemoveUser("Joe Smith")=True then

print "Joe Smith account was removed"

endif

Applies to

AUsers

See Also

AddUser, AUser, Users, UsersCount