Help with togglebutton that displays jpg

C

caj

I have a jpg that when you click the toggle button it appears and when you
click it again it goes away. Can this be done in Excel?
 
C

Chip Pearson

Put a Picture and a Toggle Button on your worksheet. Then, right-click the
sheet tab, choose "View Code" and paste the following code in that module:

Private Sub ToggleButton1_Click()
Me.Pictures("Picture1").Visible = Me.ToggleButton1.Value
End Sub

Change "Picture1" to the name assigned to the picture object.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com
(email address is on the web site)
 
Top