PC Review


Reply
Thread Tools Rate Thread

Conditional Formatting Help

 
 
Ayo
Guest
Posts: n/a
 
      19th Aug 2009
I am trying to do a conditional format on the rngInsitedata range. If the
cell value is past due I want the cell to be Red Fill and font color white.
Please help.

With rngInsitedata
.FormatConditions.Add(xlCellValue, xlEqual,"=Past Due")
With .Borders
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = 6
End With
With .Font
.Bold = True
.ColorIndex = 3
End With
End With
 
Reply With Quote
 
 
 
 
Jacob Skaria
Guest
Posts: n/a
 
      19th Aug 2009
Try the below

Sub Macro()
Dim rngInsiteData As Range
Set rngInsiteData = Range("C1:C10")

With rngInsiteData
..FormatConditions.Add Type:=xlCellValue, Operator:=xlEqual, _
Formula1:="=""Past Due"""
..FormatConditions(1).Font.ColorIndex = 2
..FormatConditions(1).Interior.ColorIndex = 3
..FormatConditions(1).Interior.Pattern = xlSolid
End With
End Sub

If this post helps click Yes
---------------
Jacob Skaria


"Ayo" wrote:

> I am trying to do a conditional format on the rngInsitedata range. If the
> cell value is past due I want the cell to be Red Fill and font color white.
> Please help.
>
> With rngInsitedata
> .FormatConditions.Add(xlCellValue, xlEqual,"=Past Due")
> With .Borders
> .LineStyle = xlContinuous
> .Weight = xlThin
> .ColorIndex = 6
> End With
> With .Font
> .Bold = True
> .ColorIndex = 3
> End With
> End With

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Conditional Formatting of text effecting formatting of background =?Utf-8?B?SEFI?= Microsoft Access Reports 6 25th Mar 2008 06:23 PM
Protect Cell Formatting including Conditional Formatting =?Utf-8?B?TWljayBKZW5uaW5ncw==?= Microsoft Excel Misc 5 13th Nov 2007 05:32 PM
Conditional Formatting No Longer Conditional in 2007 Beta =?Utf-8?B?Q2FjdHVhci1Oby1KdXRzdQ==?= Microsoft Excel Crashes 0 17th Nov 2006 10:01 PM
How do I do a complex conditional in a conditional formatting formula Ray Stevens Microsoft Excel Discussion 7 12th Mar 2006 10:24 PM
Conditional Formatting that will display conditional data =?Utf-8?B?QnJhaW5GYXJ0?= Microsoft Excel Worksheet Functions 1 13th Sep 2005 05:45 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:38 AM.