Utility Functions and C Language Reference > Utility Functions: C Language (lr_) > Alphabetical Listing > lr_whoami

lr_whoami

Returns information about the Vuser executing the script.

C Language

void lr_whoami ( int *vuser_id, char *sgroup, , int *scid  );
Example: lr_whoami Informational Functions

Arguments

Name Comments
vuser_id A pointer to an output argument to store the Vuser ID number.
sgroup A pointer to an output argument to store the name of the Vuser Group.
scid A pointer to an output argument to store the Scenario or Session step ID number.

The lr_whoami function gets information about the Vuser.

Note that the sgroup parameter is a pointer to constant data and should only be read, not altered. Memory for the string is allocated automatically. You do not have to allocate explicitly in the script.

To access the scenario ID, add the scenario attribute to the Run-Time Settings. Add scenario to the Additional Attributes on the General tab. If the scenario attribute is not added to the Run-Time Settings, the scenario ID is always zero (0).

If you do not want to retrieve one or more of the parameters, replace the parameter name with NULL.

Not applicable for products that do not run individual Vusers.

Return Values

No value is returned.

Parameterization

You cannot use standard parameterization for any arguments in this function.