Set Global Variable

Create or update a global variable
Set Global Variable Dialog
Set Global Variable Dialog
Read more in Guide > Variables

Parameters

GlobalVariableSource
GlobalVariablePersisted
Variable Name
Text required

Enter the name of the variable you would like to create or modify

Variable Name must be entered in camelCase (the first letter must be lowercase)
Source
Select required
Default:
Global

Select the source type for the global variable

  • Global - Fetch any general global variable (non user variables)
  • User (redeemer) - Fetch a user global for the current user who activated the action
  • User (target) - Fetch a user global for the targetUser
Value
Text required

Enter the value to assign to the global variable, depends on the selected Source type, detailed above

  • Argument - Enter the name of an existing argument to assign its value to the global variable
  • Value - Enter any value
  • Increment - Enter any int
  • Decrement - Enter any int

Variables

NameTypeDescription
No data

C# Usage

Set the value for a global variable

public void SetGlobalVar(string varName, object value, bool persisted = true)