Jul 01 2021 06:22 AM
Hey everyone,
Does it exist a formula that replaces a number value's sign with the opposite sign?
English is not my native language, and I do not have any experience with using English mathematical terms, so I am not sure whether or not I am expressing my question correctly. Simply what I am looking for is a formula that replaces as example "-4" with "4" and 32 with "-32".
Jul 02 2021 12:54 PM
If you mean to change the sign in the same cell, that's VBA programming, not formula.
Jul 02 2021 04:08 PM - edited Jul 02 2021 04:10 PM
If you mean to change the sign, but leave the values in the same cell, then you could input -1 into an empty cell. Then, copy that cell, select the range you want to change, right click, select paste special (a dialog box should pop up), and select "multiply." Then, delete the cell with -1 in it. Be sure to make a backup of your data before testing.
Edit: I am assuming that the numbers you want to change are constant values, i.e. the cells just contain the numbers and not formulas that result in a number.
Jul 02 2021 07:25 PM
SolutionSo far my only viable option is to multiply source cell by -1 like this:
=[source cell]*-1
This works well with my current calculator sheet, but for a future broader usage this wont work with algebraic expressions unless there is a way to make algebraic expression recognised by the application.
Jul 02 2021 07:25 PM
SolutionSo far my only viable option is to multiply source cell by -1 like this:
=[source cell]*-1
This works well with my current calculator sheet, but for a future broader usage this wont work with algebraic expressions unless there is a way to make algebraic expression recognised by the application.