Calculate the absolute value in the formula block
-
I have a problem where I want to calculate the absolute value of an expression. Should the formula be written?
Var-A is greater than Var-B and when it is subtracted from each other, it gives a negative expression.
I want this difference to be positive and to be rewritten again on Var-B. How should I do this? please guide me.

-
Has you try using a conditon above as a filter by comparing the two variables?
-
The value of Var-a in the main formula is the fixed volume of the transaction and Var-b is the variable volume that changes with each success or failure of the transaction. Var-B takes its value from Var-A and Var-A cannot be negative in case of failure! That's why I want to calculate its absolute value.
-
Do you mean you need positive values only? Then you can type '*-1' on the 'Adjust the result (optional)' box.
-
@l'andorrà I did that, but it didn't give the result I wanted. It changed the volume from 0.1 to 0.01 lot!