Hi,
I would like to know if there is a macro i can use so that when i type 'u100' in a cell and hit enter, the 'u' automatically changes to an up arrow and the text turns green. Likewise, when i type d100, it replaces the d with a down arrow and the text turns red...
u (up) for green
d (down) for red
I guess the u and d being replaced by corressponding arrows would be similar to autocorrect, but i woud also like the text to change colour per above.
Not sure if this is possible or not... And if it is, i have no idea how to code it!!
Any suggestions welcome. Thanks!
Hi morayman
Try to enter values in D2:D20
Private Sub Worksheet_Change(ByVal Target As Range) If Target.Count > 1 Then Exit Sub If Intersect(Target, [d2:d20]) Is Nothing Then Exit Sub If Not Target Like "[ud]*" Then Target.Font.Name = "Arial": Target.Font.Color = vbBlack: Exit Sub Application.EnableEvents = False Target.Font.Name = "Arial" With Target.Characters(1, 1) .Font.Name = "Marlett" .Text = IIf(.Text = "u", "t", "u") Target.Font.Color = IIf(.Text = "u", vbRed, vbGreen) End With Application.EnableEvents = True End Sub
awesome.. thanks so much
If you are satisfied with the solution(s) provided, please mark your thread as Solved.
How to mark a thread Solved
Go to the first post
Click edit
Click Go Advanced
Just below the word Title you will see a dropdown with the word No prefix.
Change to Solved
Click Save
“To sin by silence when they should protest makes cowards of men.” ~ Abraham Lincoln
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks