need some columns to auto add decimal pt & others to not - How to.
Sean,
Fixed decimals will work if you are only entering one column at a time -
otherwise, you would need to keep toggling it back and forth.
If you are entering column 1 then column 2, you could make the formula in
the 3rd column
=column2/100
then use a fourth column to do the multiplication. Hide the second column
when you are done.
OR
You could use an event to change the values in the second column: I'm
assuming column B for the code he
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column < 2 Or Target.Cells.Count < 1 Then Exit Sub
Application.EnableEvents = False
Target.Value = Target.Value / 100
Application.EnableEvents = True
End Sub
Copy the code above, right-click the sheet tab, select "View Code" and paste
the code into the window that appears.
HTH,
Bernie
MS Excel MVP
"Sean Timmons" wrote in message
...
so you want to enter the number as pire digits and have the decimal
added...
Go to Tools - Options - Edit tab
Fixed Decimal placed, check it off and make sure it says 2.
"His child" wrote:
I have a spreadsheet that in one column I enter a number that will not
have
decimal places. The next column are number with 2 decimal places. The
3rd
column multiplies the 1st 2 and has 2 decimal places. Is there a way to
enter the figures in the 2nd column that the computer would add the 2
decimal
places without my having to input the decimal. There is alot of data and
it
would be quicker if this was possible.
|