change font color for cells starting with "T "

P

Pman

Hi guys,

I have multiple columns of data in which there are many occurences of a
certain object. These values start with "T" and then there's a space and then
a code/ date [looks something like T APR01/07, or T 09102007].

I was wondering if someone could help me with a macro that changes the font
color for the columns between H and AG for cells starting with T and space,
and change the color of the values to teal (plus bold it). I tried
conditional formatting, but it doesn't have anything for cells beginning with
a certain value.

Thanks,

Pman.
 
G

Gary''s Student

You can use Conditional Formatting, say in A1:

Formula Is:

=LEFT(A1,2)="T "

and then set your desired formats
 
A

Alan Beban

Gary''s Student said:
You can use Conditional Formatting, say in A1:

Formula Is:

=LEFT(A1,2)="T "

and then set your desired formats

Or, if some cells'value may be t

=EXACT(LEFT(F8,1),"T")

Alan Beban
 
P

Pman

Thanks Guys :)

Was able to do it with a macro :)

Columns("H:AF").Select
With Application.ReplaceFormat.Font
.FontStyle = "Bold"
.Subscript = False
.ColorIndex = 13
End With
Selection.Replace What:="T *", Replacement:="", LookAt:=xlPart, _
SearchOrder:=xlByColumns, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=True

Thanks again :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top