Utility Functions and C Language Reference > Utility Functions: .NET (lr.) > Alphabetical Listing > lr.get_scenario_id

lr.scenario_id

Returns the id of the current scenario or session step.

C# Language

int lr.scenario_id();

VB.NET

Function lr.scenario_id( ) as Integer
Example: lr.scenario_id Informational Functions

Arguments

Name Comments
N/A

The lr.scenario_id property returns the current scenario or session step ID.

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).

Return Values

The scenario or session ID. If no value is available,returns -1.

Parameterization

Parameterization is not applicable to this function.