Dim rng As Range
Dim cell As Range
Set rng = Nothing
For Each cell In ActiveSheet.UsedRange
If cell.Interior.ColorIndex = 10 Then
If rng Is Nothing Then
Set rng = cell
Else
Set rng = Union(rng, cell)
End If
End If
Next cell
If Not rng Is Nothing Then
rng.Select
End If
--
HTH
RP
(remove nothere from the email address if mailing direct)
"T-容x" <T-ex.1ub8ui_1124957126.2941@excelforum-nospam.com> wrote in message
news:T-ex.1ub8ui_1124957126.2941@excelforum-nospam.com...
>
> This can be done if the cells you are trying to select are
> contiguous....
>
> Range("E5:G10).Select
>
> but if your "green" cells are scattered, e.g. only cells C2, F6 and H7
> are green, then... i can't help you with that....
>
> JamieMorien Wrote:
> > Can someone please help me. What I need to do seems simple but I can't
> > find info anywhere.
> >
> > I want to select all cells that are green for example. How can i do
> > this with VB or an alternative?
> >
> >
> > Thanks for your help
>
>
> --
> T-容x
> ------------------------------------------------------------------------
> T-容x's Profile:
http://www.excelforum.com/member.php...o&userid=26572
> View this thread: http://www.excelforum.com/showthread...hreadid=398943
>
Bookmarks