Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
How do I assign a font change to selected charecters within a cell.
Example: A1: 623154 (as text) I highlight 231 and run the macro and get this result 6²³¹54 I've been experimenting with macros lately and I wanted to make a superscript and subscript button. Here is some code I recorded (minus the junk). It is extremely simple, but I wanted to know if there was a way to apply the font change to only selected charecters in a cell. Sub Macro1() With ActiveCell.Characters(Start:=2, Length:=2).Font .Superscript = True End With End Sub Sub Macro3() With Selection.Font .Subscript = True End With End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Toolbar button for superscript | Excel Discussion (Misc queries) | |||
Superscript Button and Subscript Button | Excel Discussion (Misc queries) | |||
Button for subscript and superscript in Excel | Excel Discussion (Misc queries) | |||
Subscript & Superscript | Excel Discussion (Misc queries) |