Numbers: Convert Negative to Positive
MacBook Pro with Retina display, iOS 12.1
MacBook Pro with Retina display, iOS 12.1
If all the values in the table are 0 or negative and you want to set them all to positive then you can use the short script below.
Done in a few seconds.
SG
tell application "Numbers"
tell front document's active sheet
tell (first table whose selection range's class is range)
repeat with c in cells
set v to c's value
try
if v < 0 then set c's value to v * -1
end try
end repeat
end tell
end tell
end tell
If all the values in the table are 0 or negative and you want to set them all to positive then you can use the short script below.
Done in a few seconds.
SG
tell application "Numbers"
tell front document's active sheet
tell (first table whose selection range's class is range)
repeat with c in cells
set v to c's value
try
if v < 0 then set c's value to v * -1
end try
end repeat
end tell
end tell
end tell
What kind of sorcery is this?!
Wonderful, it worked like magic! Thank you for saving me hours of tedious possibly mistake making work!
Glad it did the trick for you. Scripts sometimes can save hours.
Thanks for the green tick!
SG
Numbers: Convert Negative to Positive