LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #4   Report Post  
Bob Phillips
 
Posts: n/a
Default

Exactly what I said.

A small tweak to my code to start at line 2 works fine

Sub ColourRows()
Dim sVal
Dim i As Long
Dim nCol As Long

sVal = Range("A2").Value
nCol = 35
For i = 2 To Cells(Rows.Count, "A").End(xlUp).Row
With Cells(i, "A")
If .Value < sVal Then
If nCol = 35 Then
nCol = xlColorIndexNone
sVal = .Value
Else
nCol = 35
End If
End If
.EntireRow.Interior.ColorIndex = nCol
End With
Next i
End Sub


--

HTH

RP
(remove nothere from the email address if mailing direct)


"reno" wrote in message
...
I did not make myelf clear. here is a sample of the actual data

LN SID# Bnr Date D FG OH 1 MFS 07/13/04 Tue
2 1 MFS 07/17/04 Sat
3 1 MFS 09/02/04 Thu 17
4 1 MFS 09/16/04 Thu 15
5 1 MFS 10/26/04 Tue 14
6 1 MFS 12/16/04 Thu 12
7 1 MFS 01/18/05 Tue 12
8 1 MFS 03/10/05 Thu Y 15
9 1 MFS 04/28/05 Thu Y 11
10 1 MFS 04/28/05 Thu Y 11
11 1 MFS 07/19/05 Tue 10
12 3 MFS 07/12/05 Tue 7
13 4 MFS 07/13/04 Tue
14 4 MFS 09/03/04 Fri 10
15 4 MFS 11/09/04 Tue 4
16 4 MFS 11/09/04 Tue 4
17 4 MFS 01/05/05 Wed 12
18 4 MFS 03/09/05 Wed Y 7
19 4 MFS 06/07/05 7 Y 4
20 5 MFS 07/16/04 Fri
What I want to do is group by alternating colors based on the account
number. The SIDS are unique and not necessarily consecutive, in this

example
there is no acct# 2. In the above example all SID 1 is green, the next

SID,3
in this case would be green and forth.
Conditional is problematic, since the SIDs are not consecutive, this would
give the effect of odd/even. In this case SIDs both SIDs 1& 3 above would

be
green using the MOD argument.

Is this a little more clear?
Thanks



 
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 Formatting Error ddate Excel Worksheet Functions 0 May 5th 05 09:00 PM
difficulty with conditional formatting Deb Excel Discussion (Misc queries) 0 March 23rd 05 06:13 PM
conditional formatting question Deb Excel Discussion (Misc queries) 0 March 23rd 05 02:07 AM
Determine cells that drive conditional formatting? Nicolle K. Excel Discussion (Misc queries) 2 January 7th 05 01:08 AM
Conditional formatting not available in Excel BAB Excel Discussion (Misc queries) 2 January 1st 05 03:33 PM


All times are GMT +1. The time now is 03:50 PM.

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

About Us

"It's about Microsoft Excel"