How to Format a Column???

  • Thread starter Thread starter robertoduran
  • Start date Start date
R

robertoduran

How can i format a Column in order to show up negative numbers in a re
color, BUT using a MACRO..



for example:

Columns("G").Select



So i want to Format this "G"Column with the option to show negativ
numbers ex: if it is -100 will show (100) in red.

Thanks
 
I just did it using the Macro Recorder and then viewed the code:

Columns("G:G").Select
Selection.NumberFormat = "#,##0.00_); _
[Red](#,##0.00)"

Of course if doing it in a Macro there is no need to actually select the
column:

Columns("G:G").NumberFormat = "#,##0.00_); _
[Red](#,##0.00)"
 
Hi
one easy way:
- start recording a macro
- apply the custom format for column G
- use this recorded macro
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top