Return Font Property

E

ExcelMonkey

I now I can set the underline property of a cell as follows:

..Font.Underline = xlUnderlineStyleSingle

But how to you return the Underline property of the cell?

?Range(Sheet!$A$1).Font.Underline produces an error

Thanks

EM
 
G

Gary''s Student

Sub testit()
MsgBox (Range("A1").Font.Underline)
End Sub

will give you a numerical value describing the underlining. For example 2
is single underlining.
 
E

ExcelMonkey

Thanks. Where do I find resources to highlight this underlying list
associated with the index number?

Thanks again.

EM
 
G

Gary''s Student

I don't know a resource. Just run a macro to reveal:

2 for single
-4119 for double
4 for single accounting
5 for double accounting
 
E

ExcelMonkey

Thanks

EM

Gary''s Student said:
I don't know a resource. Just run a macro to reveal:

2 for single
-4119 for double
4 for single accounting
5 for double accounting
 

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

Top