VirtualUser GetTransactionElapsedTime Method C# API
Gets the current elapsed time of the transaction with the specified id and tag.

Namespace: Facilita.Fc.Runtime
Assembly: fc_clr (in fc_clr.dll) Version: 9.5.8.37
Syntax

public int GetTransactionElapsedTime(
	string id,
	string tag = "",
	VirtualUserScript script = null
)

Parameters

id
Type: System String
The transaction identifier.
tag (Optional)
Type: System String
The transaction tag.
script (Optional)
Type: Facilita.Fc.Runtime VirtualUserScript
The currently executing VirtualUserScript.

Return Value

The elapsed time of the transaction, in milliseconds.
Examples

The following example demonstrates setting a progress point to indicate that a transaction has lasted more than 5 seconds.
StartTransaction("Transaction1", "Tag1");

// do activity

StartTransaction("Transaction1", "Tag2");
if (GetTransactionElapsedTime("Transaction1", "Tag1") > 5000)
{
    SetProgressPoint("Activity > 5 Seconds");
}

EndTransaction("Transaction1", true, "Tag1");

// do more activity

EndTransaction("Transaction1", true, "Tag2");
See Also