Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi everyone,
I need to find rows in Col. A with the word "Wire" as the 1st four characters, and then bold and turn red that cell along with the cells to the right of it all the way over to Col. K (not the whole row). I have the first part of the macro figured out, but am unsure how to expand the range to include the extra columns to the right. I can do it using Column Offset but that seems awfully clunky to me and I want to do this the right way. Here's what I have so far, and thanks for any help you can provide! Sub BoldTheRows() LastRow = Range("A" & Rows.Count).End(xlUp).Row Set CompareRange = Range("A1:A" & LastRow) For Each cell In CompareRange If Left(cell, 4) = "WIRE" Then With cell ..Font.Bold = True ..Font.ColorIndex = 3 End With End If Next cell End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Range that expand | Excel Discussion (Misc queries) | |||
Expand range help | Excel Programming | |||
Cannot Expand Named Range - when size of the Range exceeds | Excel Discussion (Misc queries) | |||
Expand Range | Excel Programming | |||
Find first cell in range and expand range -VBA | Excel Programming |