View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Gary''s Student
 
Posts: n/a
Default code for changing font

Try using something like:

..Font.Bold = True
--
Gary's Student


"Jack Sons" wrote:

Hi all,

With the code below I want to change all red Wide Latin text in range
A2:F100 into black, bold (in my Dutch version the word for "bold" is "vet"),
Times New Roman.

It will not work at all. What's wrong?

Jack Sons
The Netherlands
------------------------------------------------------------------------------------
Sub Change()

Dim rng As Range
Dim rCell As Range

Set rng = Range("A2:F100")

For Each rCell In rng.Cells

With rCell

If .Font.Name = "Wide Latin" Then
.Font.Name = "Times New Roman"
.Font.ColorIndex = 1
.FontStyle = "vet"
End If

End With

Next rCell

End Sub