Thread: Font.ColorIndex
View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
kirkm[_8_] kirkm[_8_] is offline
external usenet poster
 
Posts: 166
Default Font.ColorIndex

On Fri, 6 Feb 2009 00:39:02 -0800, Mike H
wrote:

Hi,

It will return that if the colorindex is xlautomatic

Try this

Range("a1").Font.ColorIndex = xlAutomatic
Debug.Print Worksheets("Sheet").Range("a1").Font.ColorIndex


Thanks Mike. I found that first line turns the text to black and
-4105 is the result.

Does this mean if you set it to NOT xlAutomtatic it will return
(what seems) the right number ?

How would you make it so, and does this also change the text colour?
I'd rather just detect the colour, not alter it.
Cheers - Kirk