Change Glow each time picture is clicked

FootBallBat

Board Regular
Joined
Jan 26, 2012
Messages
169
I'm creating a score keeping spreadsheet for game night.
I have 2 images below. What I am looking for is: I want to be able to click an image (card) and it adds a glow, then when you click it again the glow disappears.
I know how to assign a macro to an image but do not know how to do an "if" statement so that if it has a glow it removes it when clicked.
P.S. If this is to complex I am willing to change it, I mainly just want a way to click on the cards you have in your hand and they highlight in a way that is easy to see (like if your grandparents were looking at it lol)

Here is the macro I asigned for the glow to be added:
Sub Change_Color()
ActiveSheet.Shapes.Range(Array("Picture 117")).Select
With Selection.ShapeRange.Glow
.Color.RGB = RGB(0, 176, 240)
.Transparency = 0
.Radius = 10
End With
End Sub
https://drive.google.com/open?id=1uCN5qzzNzlww4iHwyhrE7ihGlAKlA5Xr
https://drive.google.com/open?id=1-SSNNgBa-8k9hl5j2_3DEOFqwsMWpcMt
 
Ok....now we are on a different track !!
Until I entered this thread, I had never heard of Glow in Excel....so were both newbies here !!
These 2 macros will color and clean.....obvious by their titles
So, click on a card run macro Colorem

When finished run macro Cleanem

Code:
Sub Cleanem()
Dim shape As shape
For Each shape In ActiveSheet.Shapes
shape.Select
With Selection.ShapeRange.Glow
        .Color.RGB = RGB(0, 0, 0)
        .Radius = 0
    End With
Next
End Sub


Code:
Sub Colorem()
Dim nu As shape
Set nu = ActiveSheet.Shapes(Selection.Name)
nu.Select
With Selection.ShapeRange.Glow
        .Color.RGB = RGB(0, 176, 240)
        .Radius = 10
    End With
End Sub
 
Last edited:
Upvote 0

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).

Forum statistics

Threads
1,223,238
Messages
6,170,939
Members
452,368
Latest member
jayp2104

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top