User Object

The User object represents a GDB user. The User object enables to set the user password, to get and set permissions of access to GDB components.

To create a new user in GDB, the following steps should be performed:

To create the User object by the GeoDatabase::CreateUser method. The created user has the same permissions as the current user.

To set required permissions to the user on GDB components.

To add the user to the GeoDatabase::Users collection by the Append method. The first added user is an administrator. The administrator has full permissions on GDB components. Only the administrator can remove all users from GDB (including himself).

If adding the user to the GeoDatabase::Users collection has succeeded, this user gets an internal number. Continuity of user numbers is not guaranteed. Assigned internal numbers do not change between GDB sessions. Internal numbers may change at GDB reorganization performed by the GDBEngine::CompactGDB method with the gdbCompactNoKeepISN mode.

To access users in the GeoDatabase::Users collection, use the Item method. The argument of the method can be a string (the user name) or an integer (the user internal number).