Support Portal

for ProcessRobot and WinAutomation

Start a new topic

Subtracting 2 variables

my example involves a bunch of text then inventory matches = 1909 reset screen

i am trying to grab subtext from text (1909),

i am currently using ParseText to find text "inventory matches = ", then another ParseText to find another text "reset screen"

"inventory matches = " has 20 characters.

So i want to subtract %variable2% - (%variable1% + 20) in order to grab the 1909 value.  But i cant subtract variables or add a numerical value to variable

what is proper way?  thanks

Hi Jon

I would do this one with Regular Expressions.

First, one that looks for the complete sentence. Then, one that identifies the number.

Check out the attached process. to learn more about the method for finding text.

1. Arithmetic Set %var_3% = %var_2 - var_1% 2. Regex (?<=inventory matches =\s+)\d+

1 person likes this
Login or Signup to post a comment