Excel help.....

archiesdad

Midfield
Oh wise ones I need some help.

I want to create a macro 'button' on a spread sheet so when you 'press' it it will turn whichever cell you have highlighted (maybe I mean the cell the curser is on) on that spread sheet a different colour ? I've nee idea if that makes any sense but I hope it does to someone :)

ps - I am a technophobe..... please be gentle.
 


Try this:

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
With Target
.Worksheet.Cells.FormatConditions.Delete
.FormatConditions.Add xlExpression, , "TRUE"
.FormatConditions(1).Interior.Color = vbYellow
End With
End Sub
 
Oh wise ones I need some help.

I want to create a macro 'button' on a spread sheet so when you 'press' it it will turn whichever cell you have highlighted (maybe I mean the cell the curser is on) on that spread sheet a different colour ? I've nee idea if that makes any sense but I hope it does to someone :)

ps - I am a technophobe..... please be gentle.

Maybe I am missing the obvious here. Excel has a button in the ribbon to change cell colour. Highlight the cell(s). Press the button.

Logon or register to see this image


^that one is for text, the cell colour version is exactly the same and is positioned next to it.
 
Oh wise ones I need some help.

I want to create a macro 'button' on a spread sheet so when you 'press' it it will turn whichever cell you have highlighted (maybe I mean the cell the curser is on) on that spread sheet a different colour ? I've nee idea if that makes any sense but I hope it does to someone :)

ps - I am a technophobe..... please be gentle.

Shirley the curser will be on the button when you click it?
 

Back
Top