Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 12
Default Conditional Font Color

How can I change the Font color based on a number?

I tried:

For Each Cell In Selection

On Error Resume Next

If Cell.Value < 140 Then Cell.Interior.ColorIndex = 30
If Cell.Value < 140 Then Cell.Font.ColorIndex = 2


'other code for lower temperatures

Next


Thanks for any help! Jim


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,494
Default Conditional Font Color

seems to work here, you just have to have the cells selected before you
execute the code

--


Gary


"Jim Brass" wrote in message
...
How can I change the Font color based on a number?

I tried:

For Each Cell In Selection

On Error Resume Next

If Cell.Value < 140 Then Cell.Interior.ColorIndex = 30
If Cell.Value < 140 Then Cell.Font.ColorIndex = 2


'other code for lower temperatures

Next


Thanks for any help! Jim



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Conditional Format for font color using font color Jim Excel Worksheet Functions 2 August 29th 09 11:54 AM
Conditional Format Font Color for more than 3 conditions abusymomforever Excel Worksheet Functions 3 February 23rd 09 09:48 PM
Excel 2007 Conditional Font Color How To? M Excel Discussion (Misc queries) 1 November 11th 08 04:08 PM
Change Font Color Based on Conditional Formatting tj Excel Worksheet Functions 8 October 11th 08 02:08 AM
Changing Font color based on font type or size John Excel Discussion (Misc queries) 2 February 7th 08 12:50 AM


All times are GMT +1. The time now is 05:53 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"