title: Protect/Unprotect chart sheets
body: <p>So I have these simple subs to unprotect than protect stuff while my macros are running, only problem is that some of my sheets are actually charts and they don't get protected when these subs are called. How can I change my code to incorporate the Charts as well? Thanks!</p>
  
  <pre><code>Sub UnprotectAll()
  
    Dim AdminPassword As String
    AdminPassword = "password"
  
    ActiveWorkbook.Unprotect ("Evaluate(AdminPassword)")
  
    For Each sh In ActiveWorkbook.Worksheets
      sh.Unprotect Password:=AdminPassword
    Next sh
  
  End Sub
  
  Sub ProtectAll()
  
    Dim AdminPassword As String
    AdminPassword = "password"
  
    ActiveWorkbook.Protect ("Evaluate(AdminPassword)")
  
    For Each sh In ActiveWorkbook.Worksheets
      sh.Protect Password:=AdminPassword
    Next sh
  
  End Sub
  </code></pre>