So, I have the following code that show/hide a shape based on a cell value that works. But the problem is that if I open another workbook, unrelated to this one it throws a acccess denied error. Any ideas why?
Private Sub Worksheet_Calculate() If ThisWorkbook.Sheets("Admin").Range("m24").Value = "YES" Then Me.Shapes("Rectangle 5").Visible = True Else Me.Shapes("Rectangle 5").Visible = False End If End sub
Bookmarks