I've searched around and can't seem to find the exact answer. I have a shape on my sheet called Dashboard, I then have a master calculator tab which will display a message based on the values of the cells I am calculating. I need to show the shape if the value is 1, hide the shape if the value is 2.
The trouble I am having is referencing another sheet where the code is for the VB. Its probably simple I am sure. I need to reference the Sheet by names, not Active sheet if that makes sense.
How do I modify this code? My cell value 1 or 0 will be in the Calculator Sheet, in cell T10, the shape is on the Dashboard sheet called Flag1
Private Sub Worksheet_Activate()
If Range("A1").Value = "DR" Then
ActiveSheet.Shapes("Flag1").Visible = False
Else
ActiveSheet.Shapes("Flag1").Visible = True
End If
End Sub
The trouble I am having is referencing another sheet where the code is for the VB. Its probably simple I am sure. I need to reference the Sheet by names, not Active sheet if that makes sense.
How do I modify this code? My cell value 1 or 0 will be in the Calculator Sheet, in cell T10, the shape is on the Dashboard sheet called Flag1
Private Sub Worksheet_Activate()
If Range("A1").Value = "DR" Then
ActiveSheet.Shapes("Flag1").Visible = False
Else
ActiveSheet.Shapes("Flag1").Visible = True
End If
End Sub