StepwiseRPA: Variable Token Config

Configuring Tokens to Perform Actions on Variables

Variables are a powerful feature of RPA systems, allowing you to store, update, and access values whenever your bot needs them. StepwiseRPA’s variable system is especially powerful as it can perform functions (see list below for valid functions) on variables when their values are accessed. The token configuration window enables you to configure multiple functions for a token, and even supports nested variable tokens with functions.

Accessing the Token Configuration Window

  1. Right-click on the Variable you want to perform functions on, the select ‘Configure Token’ in the context menu.
DataRow Functions
  • Get Value at Col Index
  • Get Value at Col Name
DataTable Functions
  • Get Value at Row/Col
  • Row Count
  • Column Count
Date Functions
  • Today
  • Now
  • Format Date
  • Add Days
  • Add Months
  • Add Years
  • Add Hours
  • Add Minutes
  • Add Seconds
  • First of Month
  • Last of Month
  • Monday of Week
  • Day of Month
  • Month Number
  • Year
  • Hours
  • Minutes
  • Seconds
  • Name of Day
  • Name of Month
  • Convert to Date
  • Convert UTC to Local
Email Functions
  • Sender Email
  • Sender Name
  • Recipients
  • Subject
  • Body
  • Body HTML
  • Date Received
  • Priority
  • File Paths
  • Attachment Count
File Functions
  • Get Filename from Path
  • Get Filename (no Ext)
  • Get File Extension
  • Get Extension (no Dot)
  • Get Folder (no Filename)
  • Combine File Parts
    • Note: does not use the value of the base variable for the token, so you must add all file parts to the Combine File Parts field (comma separated)
  • Add File Parts
    • Note: uses the value of the base variable for first portion of the file path
  • Random File Name (no ext)
  • Random File Name – allows you to supply an extension to add
General Functions
  • Bot Name
  • Step Name
  • Step Number
  • Pass Count – gets the count of Transactions that ‘Passed’. You use ‘Add to Pass Count’ step action to increment count
  • Fail Count – gets the count of Transactions that ‘Failed’. You use ‘Add to Fail Count’ step action to increment count
  • Error Count – gets number of errors Bot encountered
  • Ignored Error Count – gets number of errors ignored becuase Step was set to ‘Ignore Errors’ in the step settings
  • Use Value for Calc – allows you to temporarily replace the value of the base variable of the token for purposes of the current variable calculation
  • Set Value to Result – sets the variable value to the result of the current calculation at the point in the calculation that the ‘Set Value to Result’ command appears.
    • Note: calculations are performed sequentially in the order that the commands appear in your configured token
    • In order to set the variable to the final value of the calculation, you should place the ‘Set Value to Result’ command in the last place in the tokens command list
  • Get Computer Name
  • Get IP Address
  • Logged In User – if StepwiseRPA is logged in to the StepwiseRPA Mission Control, this returns the logged in username (an email address)
  • Windows User
  • Win/Domain User – gets Windows/Domain user
  • Wait – will pause n milliseconds at the point in the calculation at which the ‘Wait’ command appears
  • Description – allows you to add comments to a variable that will be ignored during variable substitution
  • Robot Ascii Art – d[00]b  – it looks like a robot
List Functions
  • Get Value at Index
  • Join List Items – joins list items into a single string separated by the character(s) you enter
    • No SQL Parameter – this has no effect on the string
    • Text/Date Parameter – wraps each list item in a tag that tells StepwiseRPA to create an SQL Parameter when used in the the MS SQL Server query – only use this when running ‘Raw SQL’ queries
    • Number Parameter – same as above except for parameters that SQL will treat as numbers
    • GUID Parameter – same as above except for parameters that SQL will treat as GUIDs or uniqueidentifier data type
  • Item Count
Number Functions
  • Format Number
  • Add to Value
  • Multiply By
  • Divide By
  • MOD – performs a Modulo operation and returns the remainder
  • Random Number
  • Round
  • Convert to Number
Text Functions
  • Left
  • Right
  • SubString
  • Pad Left
  • Pad Right
  • Replace Text
  • Replace Line Breaks
  • Remove Text
  • Remove Line Breaks
  • Remove Whitespace
  • Remove from Start
  • Remove from End
  • Trim
  • Trim Left
  • Trim Right
  • Text Length
  • Encode Base64
  • Decode Base64
  • Encode HTML
  • Decode HTML
  • Convert HTML to Text
  • URL Encode
  • URL Decode
  • Encode for Replace
  • Escape Double-Quotes
  • Wrap in Quotes
  • MD5 Hash
  • SHA256 Hash
  • Random String
  • Split String
  • To Upper Case
  • To Lower Case
  • To Title Case
  • Normalize Line Breaks
  • Line Break
  • AES256 Encrypt-Auto Salt
  • AES256 Encrypt-Manual Salt
  • Format JSON – makes JSON string readable by adding line breaks and indents
  • Convert JSON to XML – converts a JSON string to XML string
  • Convert XML to JSON – converts an XML string to JSON string
Workbook (Excel & Quick Calc Sheets)
  • First Sheet Name – gets first sheet name in a workbook
  • Sheet Name at Index
  • Get Cell Value – when using an Excel or Quick Calc variable, will return the cell value for the sheet name and cell reference entered
  • Set Cell Value – when using an Excel or Quick Calc variable, will set the cell value for the sheet name and cell reference entered