User Guide

Please email training@callscripter.com for omissions or errors.
×
Menu

System Variable List

The following list defines the most commonly used system variables.  The system variable list can be accessed from any script when in the script editor, by going to Tools --> Script Variables.  From here, you can create your own script variables, or search for existing System Variables and a description of their function:
 
 

GLOBAL VARIABLES

Global variables are populated automatically
Auto-Populated
var_callername 
Fields named 'Forename' and 'Surname' are concatenated into this variable.  The content can also be set in the same way as any other variable if required.
Yes
var_csAgentID
The ID of the Agent running the script
Yes
var_csAgentName
The full name (Firstname lastname) of the Agent running the script as defined in the user manager
Yes
var_csAgentUserName
The User/login id of the Agent running the script as defined in the user manager
Yes
var_csClientMachine
The IP Address of the machine name of the client computer accessing the executor
 
var_csFirstName
The Firstname of the Agent running the script as defined in the user manager
Yes
var_csLastName
The Lastname of the Agent running the script as defined in the user manager
Yes
var_csCustomerID
The ID of the customer to which the script belongs
Yes
var_csCustomerName
The Name of the customer to which the script belongs
Yes
var_csScriptEditorMode
If set to true the executer will treat this as a script editor initiated script run and close the script accordingly
 
var_csScriptID
The ID of the current script
Yes
var_csScriptName
The name of the current script
Yes
var_csSessionID
The current session ID.  A unique identifier for each script run.  Automatically populated and stored in the CallScripter Database.
Yes
var_csStampProductRevenue
Creates a billing event for the revenue of products sold
 
var_csStartDate
The date on which the current script run commenced.   Automatically populated and stored in the CallScripter Database.
Yes
var_csStartTime
The time at which the current script run commenced.   Automatically populated and stored in the CallScripter Database.
Yes

ORDERING VARIABLES

 
Auto-Populated
var_csOrderGrandTotal
Returns the total order amount (cost)
If shopping basket control used
var_csOrderPostageTotal
Returns the total order postage amount (cost)
If shopping basket control used
var_csOrderProducts
Returns the total number of products ordered
If shopping basket control used
var_csOrderProductTotal
Returns the total order product amount (cost, excluding postage cost)
If shopping basket control used
var_csOrderQuantities
Returns the total number of quantities ordered
If shopping basket control used
var_csProductsMessage
Displays a custom message upon opening of the Shopping Basket
If shopping basket control used
var_maxproducts
The maximum number of products allowed to be added to the shopping basket
 
var_maxqty
The maximum quantity allowed in the shopping basket
 
var_prod_max_qty
The maximum quantity allowed per product in the shopping basket
 
var_ordersubtotal 
 To contain a Subtotal for current order (excluding p&p and special offers)
If shopping basket control used
var_ordertotal 
 Total for current order
If shopping basket control used
var_ordersubcount 
 How many products ordered
If shopping basket control used
var_overallsubtotal 
 Subtotal for all orders
If shopping basket control used
var_overalltotal 
 Total for all orders
If shopping basket control used
var_ordercount
 Number of each product ordered (not the number of individual products)
If shopping basket control used
var_select_basket_group*
Set the product group to display in the basket.
 
var_select_basket_orderby*
Set the order to display products in the basket. Valid values are product_code,product_cost or product_name.
 
var_select_basket_tag
Set the tag to use for the products in the basket.
 

OUTBOUND VARIABLES

 
Auto-Populated
var_name 
Company / contact name for current outbound record
Auto 
var_reference 
Outbound Reference number for record
Auto
var_telno 
Telephone number to be called for current outbound record.  Tel No 1 as mapped in the outbound manager
Auto
var_calltype 
Set to 'NEW' or 'RESCHEDULED' call depending on call status of current record
Auto
var_csCampaignID
The ID of the current campaign
Auto
var_csCampaignName
The name of the current campaign
Auto
var_csCallListID
Contains the id of the call list in which the current record resides
Auto
var_csCallListName
Contains the name of the call list in which the current record resides.
Auto
var_obCallComplete 
This can be set to 'yes' or 'no' to indicate whether or not you need to make more calls to this record
No
var_obComments 
 Any comments added to this variable will be added to the current outbound record
No
var_obOutcome 
 Sets the call outcome of the current outbound record. The value needs to match a campaign outcome.
No
var_obPriority 
 Sets the priority of the record. Leave blank to not change. Ignored if record is set to Bottom of List. Populated with an integer
No
var_obRescheduleType 
 If the call / current outbound record is not complete, this can be set to 'callback', 'reschedule' or 'bottom'
No
var_obRescheduleTime 
 Sets the time the current record will be rescheduled for, or alternatively choose which predefined callback time will apply (from the callbacks set up for the current campaign), by setting the name here
No
var_obRescheduleTo 
 Sets the agent to reschedule the current record to by assigning the agent ID (or 0 for all agents)
No
var_obHandleOutcomeInScript 
Flags whether or not to use script variables to set the outcome/reschedules etc. When used, this must be the first variable used in the calculate field. Populate with 'Yes' to enable this
No

EMAIL VARIABLES

 
Auto-Populated
var_emEmailID 
 Holds the ID for the current email
If email connection mgr used
var_emExit 
 Flags whether or not to exit after the current email, flags whether or not to exit after the current email, populate with 'yes' to enable this.
If email connection mgr used
var_emHandleOutcomeInScript 
 Flags whether or not to use script variables to set the outcome and notes, populate with 'yes' to enable this
If email connection mgr used
var_emNotes 
 The notes for the current email
If email connection mgr used
var_emOutcome 
 The outcome of the current email
If email connection mgr used

LANGUAGE VARIABLES

 
 
var_csLanguages
 Used by the multi lingual code to specify which language to currently display.  The Variable must be added as a script variable. Populated with the column name of the chosen language to switch to
No

SPECIAL VARIABLES

 
Auto-Populated
var_DDI
Add this as a script variable.  It will automatically be populated with the incoming DDI.  Useful if you have multiple DDIs for the same script and want to know which number the caller dialled.  This can be used in conjunction with var_csLanguage to display different language versions of the script for different DDI numbers.    
Yes
var_CLI
Add this as a script variable. Will be populated automatically with the caller's number where available.
Yes
var_csMQID
Add this as a script variable.  Unique number created for each task. 
Yes
var_csMQReference
Add this as a script variable.  Parent/group number of tasks, so if multiple tasks are inserted using one Task Management - Insert control, Reference is the number that groups them (this is useful if a group of tasks needs to be cancelled).
Yes
var_csMQTasks
Add this as a script variable.  Name of specific task set in the Task Management - Insert control.  Variable needs to be added to script, no other coding required to enable functionality.
Yes
 
var_reportid
Add this as a script variable. If you set this variable to be equal to the ID of a report you can dynamically send reports from any of the Report runner controls in CallScripter.
No
 
* The var_select_basket_group and  var_select_basket_orderby variables replace the functionality shown here for  versions of CallScripter 4.5.17+ allowing the script builder to control the group and order by in the script instead and meaning that the options though available in the Shopping Basket control  are ignored.