I have an older version of UiPath that does not have “Subtract” but I want to decrease a number, pulled from an excel sheet, to be one year less. For example, if I am pulling 2019, I want the number to actually be 2018. How can I do this without the Subtract Formula function?
Let us take you retrieved a value from Excel as strA
Create One more variable strb
Now use Assign Activity
strb = (Convert.ToInt32(strA)-1).ToString
Regards,
Mahesh
Hello @Mitchell_Binder
first you have to inject python and then pass two value in that argument of activity.
.py file
int subtractValue(x,y)
{
while
(y != 0)
{
int
borrow = (~x) & y;
x = x ^ y;
y = borrow << 1;
}
return
x;
}