Converting numbers

  • Thread starter Thread starter Mike
  • Start date Start date
M

Mike

Can somebody outthere please help me wit this issue. How
do i convert a positive number into negative, when there
is a column full of numbers that needs to be converted
 
Hi Mike,

Im an empty cell, enter the number -1. Edit>Copy.
Select your column, Edit>Paste Special, check Multiply


--
Kind Regards,

Niek Otten

Microsoft MVP - Excel
 
Mike,

This bit of code converts column A

Sub Convert()
Dim cell As Range

For Each cell In Range("A1:A" & Cells(Rows.Count, "A").End(xlUp).Row)
cell.Value = Abs(cell.Value)
Next cell

End Sub


--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
Niek,

This will negate any negative numbers in the column.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
Bob,

This will negate any negative numbers in the column. <VBG> ( Beat you to it
Niek!! :-> )

Sub Convert()
Dim cell As Range

For Each cell In Range("A1:A" & Cells(Rows.Count, "A").End(xlUp).Row)
cell.Value = -Abs(cell.Value)
Next cell

End Sub
 
Back
Top