ipbr21054
Well-known Member
- Joined
- Nov 16, 2010
- Messages
- 5,832
- Office Version
- 2007
- Platform
- Windows
Hi,
When i apply a hyperlink to some text in a cell it defaults to say size 16 but i would like it at size 11
I have the following but i dont see it change when i leave the cell.
The applied for all cells in column Y
Please advise thanks.
When i apply a hyperlink to some text in a cell it defaults to say size 16 but i would like it at size 11
I have the following but i dont see it change when i leave the cell.
The applied for all cells in column Y
Please advise thanks.
Rich (BB code):
Private Sub Worksheet_Change(ByVal Target As Range)
Dim Rng As Range
Dim cell As Range
Set Rng = Intersect(Target, Range("6:" & Rows.Count), Range("A:L,N:W"))
' Exit if nothing entered into out target range
If Rng Is Nothing Then Exit Sub
' Loop through all cells in our target range
Application.EnableEvents = False
For Each cell In Rng
cell = UCase(cell)
Next cell
Application.EnableEvents = True
If Not Intersect(Target, Range("L6:L" & Range("L" & Rows.Count).Row)) Is Nothing And Target.Cells.Count = 1 Then
Application.EnableEvents = False
With Target
.Interior.ColorIndex = 6
.Font.Size = 11
.BorderAround xlContinuous, xlThin
.Font.Name = "Calibri"
.Font.Bold = True
.HorizontalAlignment = xlCenter
.VerticalAlignment = xlVAlignCenter
End With
.Range ("Y6:Y")
.Interior.ColorIndex = 2
.Font.Size = 11
.BorderAround xlContinuous, xlThin
.Font.Name = "Calibri"
.Font.Bold = True
.HorizontalAlignment = xlCenter
.VerticalAlignment = xlVAlignCenter
Application.EnableEvents = True
End If
End Sub