Help Center
Welcome to the WalkMe Help Center

Please login in order to continue:

Work flows better with WalkMe
Work flows better with WalkMe.

Variables Cheatsheet

Last Updated April 17, 2024

What are Variables?

A variable contains useful information about a user such as role, access level, department, email or user ID that is stored on a web page.

How Does WalkMe Use Variables?

WalkMe points to variables in order to read information about the user type, roles in the organization, and access level. WalkMe uses the information to segment WalkMe assets in order to target specific user groups. WalkMe does not change or alter any information on your site.

Segmentation

Variables are particularly useful in identifying user attributes such as roles, Salesforce Admin Access, and department. This information can be used to segment the WalkMe items you build to ensure that only content relevant to that user type is visible.

Reports

Variables can also store information unique to the user such as an email or ID number. With this information we can create reports about individual users to monitor their usage of WalkMe and completion of important businesses processes.

How To Create a Variable

Any variable which is accessible from the global window scope can be read by WalkMe. Variables already in your system can be easily adapted so that WalkMe can point to them. In order for WalkMe to read a variable, it must be attached to the window object.

Variables that WalkMe points to must be:

  • Accessible within the web browser console/on the page level
  • Must be on every page

The best resource for creating these variables is your Development or IT Team. In order to effectively communicate to the relevant team, outline what your variable is supposed to measure (the different values) and the name of the variable you'd like created.

For example, you could have a variable called User_Profile that contains values such as Admin, Sales, Marketing, Management, etc. Other commonly used variables are ones that identify a unique user ID, permission level, or the date the user signed up for the platform. A Global Variable is attached to the window object and can be read by WalkMe at any time.

Once you have identified or created a variable, we can configure WalkMe to track or segment by this information.

Variable example

var userRole = user.getUserRole()

In this example, a new variable called user role is declared using the object name and a function to call the relevant data. The object can relate to any data you already store about your user.

Attaching a variable to the window object

window.userRole = userRole

Once the variable has been defined, we can use the template above to attach the var to the window object.

Configuring Variables with WalkMe

Once your variables have been created, you will need to configure WalkMe to look for them.

  1. Click on the Settings icon and select System settings
  2. In the General tab, type in the name of your variable
Note

This configuration applies only to variables that are being used for analytics purposes or for Onboarding tasks. If variables are being used solely for segmentation no configuration is necessary, however any variables configured in this manner will still be available for segmentation.

Using Variables for Segmentation

To use your variable in a segment, follow these steps:

  1. Click Manage segments
  2. Create a new segment or edit an existing one
  3. Click on the pencil icon to create rules for the segment
  4. Click Add Rule
  5. Select User Data from the Rule Type dropdown, then select Variable
  6. Type in your variable name
  7. Select an operator and enter the variable value you want to segment by

Tip Tuesday Video

Was this article helpful?

Thanks for your feedback!

Be part of something bigger.

Engage with peers, ask questions, share ideas

Ask the Community
×