Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Format Currency problem

Status
Not open for further replies.

cassidybklyn

Programmer
Apr 23, 2007
82
US
Gentlemen, please bear with me:
I am having a problem farmating one column("D"), whose value is currency. I am using this code which I got from recording a macro:
Selection.NumberFormat = "$#,##0.00;[Red]$#,##0.00" Columns("D:D").select.

Using the above code, all numbers in the spreadsheet conversts to currency, but my objective is to make the the values in only column "D" currency.
Please help.
Thanks.
Cassidy.
 
What about this ?
Columns("D:D").NumberFormat = "$#,##0.00;[Red]$#,##0.00"

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
Columns("D:D").Select
Selection.NumberFormat = "$#,##0.00;[Red]$#,##0.00"

I hope this helps


Ron Repp

If gray hair is a sign of wisdom, then I'm a genius.
 
Ron: Why select? Wouldn't PH's suggestion (the same thing without selecting first) be more efficient?

[tt]_____
[blue]-John[/blue][/tt]
[tab][red]The plural of anecdote is not data[/red]

Help us help you. Please read FAQ181-2886 before posting.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top