mldap_get_attrib_value

Example: mldap_get_attrib_valueListing Directory Vuser Functions (MLDAP)

Gets the value of the specified attribute.

char *mldap_get_attrib_value( char *transaction, char *name, char *index, [char *offset,] [char *param,] LAST );
transactionA transaction name for this step. To instruct VuGen not to create a transaction for this step, use a NULL string, "".
name The name of the attribute. Specify either name or index, not both.Use the format: Name=attribute_name
index The index of the attribute. Specify either name or index, not both. Use the format: Index=attribute_number
offset The zero-based offset of the attribute value. For the first value of an attribute (default), specify a 0. Use the format: offset=offset
param The name of a parameter storing the value. Use the following format: "Param=name"
LAST A marker indicating the end of the argument list.

The mldap_get_attrib_value function retrieves the value of an attribute of the current entry. You can specify either the index of an attribute or its name. By default, if nothing is specified, the function returns the value of the first attribute. The optional offset argument lets you get an attribute value other than the first. For example, if an attribute has multiple values, an offset of 0 would return the first value, an offset of 1 would return the second, etc.

This function is for use with global sessions. For multiple sessions, use the mldap_get_attrib_value_ex function, which allows you to specify a session identifier.

This function is not recorded. Add it if needed when enhancing your script.

Return Values

This function returns the attribute value, or NULL if no entries are available or if there is an error.

Parameterization

The following argument(s) can be parameterized with standard parameterization: name, index, offset, paramtext