PDA

View Full Version : simple formating problem



buddy2000
02-19-2011, 11:50 AM
I need to format the number into currency.


.Range("b6").Offset(0, 0).Value = " $######.##"; 450000

Bob Phillips
02-19-2011, 12:16 PM
.Range("b6").Offset(0, 0).Numberformat= " $#,##0.00"

buddy2000
02-19-2011, 12:33 PM
I am sorry I do not understand. I need the .value so it will send the correct number to the cell. I need to know how to add the fomating part to the line of code I already have.

buddy2000
02-19-2011, 12:37 PM
Here is the original code I had. I need to know how to format the value to currency. All of the syntax I can find just shows you a short example. They do not show you how to incorporate the syntax into a line of code.

Worksheets("someworksheet").Range("b6").Offset(0, 0).Value = 4500000

Bob Phillips
02-19-2011, 12:44 PM
With Worksheets("someworksheet").Range("b6").Offset(0, 0)

.Value = 4500000
.Numberformat="$#,##0.00"
End With