Forum Discussion
Greg Bonaparte
Jul 30, 2020Iron Contributor
MULTIPLY NEGATIVE NUMBERS
The following macro needs to be false if BD an BE are negative values. I'm not clear how to. The formula used in cell BF... is =(BD...)*(BE...) Sub BFSORT()
Application.Calculation = xlManual
...
NikolinoDE
Jul 30, 2020Platinum Contributor
You can simply convert them to positive values with ABS (). Explicit option Public Sub test () Dim variable as double variable = -123 MsgBox variable variable = Abs (variable) MsgBox variable End Sub If you have solved your problem with this solution, please mark it as the correct answer so that others can also get this information. If this is not what you are looking for, please give us a quick feedback. Nikolino I know I don't know anything (Socrates)