Change Macro button color after clicked

C

Cong Nguyen

Is there a command to change the Macro button to another color after clicked?
Many thanks.
 
D

Don Guillett

I used a shape from the drawing tool bar>recorded this>added msgbox "hi".
Play with it

Sub Macro7()
'
' Macro7 Macro
' Macro recorded 11/30/2007 by Donald B. Guillett
'

'
MsgBox "hi"

ActiveSheet.Shapes("Rectangle 1").Select
Selection.ShapeRange.Fill.Visible = msoTrue
Selection.ShapeRange.Fill.Solid
' chg number below
Selection.ShapeRange.Fill.ForeColor.SchemeColor = 66
Selection.ShapeRange.Fill.Transparency = 0#
Selection.ShapeRange.Line.Weight = 0.75
Selection.ShapeRange.Line.DashStyle = msoLineSolid
Selection.ShapeRange.Line.Style = msoLineSingle
Selection.ShapeRange.Line.Transparency = 0#
Selection.ShapeRange.Line.Visible = msoTrue
Selection.ShapeRange.Line.ForeColor.SchemeColor = 66
Selection.ShapeRange.Line.BackColor.RGB = RGB(255, 255, 255)
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top