Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have now managed to find a solution:-
Sub EditFont() 'To format font color for 12 digits to 4 black, 5 red, 3 black: 123456789012 'First, format digits to be treated as characters ActiveCell.Value = "'" & ActiveCell.Value 'Format all characters for black With ActiveCell ..Font.ColorIndex = 3 'Format characters 5 thru 12 as red ..Characters(1, ActiveCell.Characters.Count - 8).Font.ColorIndex = 1 'Reformat characters 10 thru 12 back to black ..Characters(10, ActiveCell.Characters.Count - 3).Font.ColorIndex = 1 End With |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How do I format part of a text cell, but not the whole thing? | Excel Discussion (Misc queries) | |||
format color of text in part of a cell | Excel Discussion (Misc queries) | |||
Text as part of Cell Format | Excel Discussion (Misc queries) | |||
format part of text in a cell? | Excel Discussion (Misc queries) | |||
How do I format text that is part of a formula? | Excel Discussion (Misc queries) |