Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Hi all! I got some help with this bit of code, but i wanted to modify it a little. I haven't had any luck. I was hoping to check the values of a couple of cells rather than just "G14:S14" (eg: G13:S13...G17:S17) This bit of code works, however i'm not sure how to get it to read each of the rows. The conditions are the same for each row. Any help would be greatly appreciated!! Thanks Private Sub Worksheet_Change(ByVal Target As Range) Dim bOk as Boolean, cell as Range Dim icolor As Integer If Not Intersect(Target, Range("G14:S14")) Is Nothing Then bOk = True for each cell in Range("G14:S14") if not isdate(cell.Value) then if cell.Text < "N/A" then bOK = False exit for end if end if Next If bOk then Range("F14").Interior.ColorIndex = 4 Else Range("F14").Interior.ColorIndex = 0 End If End if End Sub -- viewmaster ------------------------------------------------------------------------ viewmaster's Profile: http://www.excelforum.com/member.php...o&userid=32094 View this thread: http://www.excelforum.com/showthread...hreadid=519227 |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Changing the colour of a range of cells, some with formulas. | Excel Worksheet Functions | |||
Changing background colour when changing data in a cell | Excel Discussion (Misc queries) | |||
Changing fill colour of cells in a range | Excel Discussion (Misc queries) | |||
Changing a cell colour | Excel Discussion (Misc queries) | |||
Changing Cell Colour | Excel Programming |