title: Is there a way to increase efficiency of unprotecting a large range upon worksheet activation in Excel VBA?
body: <p>I currently have a worksheet that, upon activation, unlocks a portion of the worksheet for user entry, but protects the rest of the worksheet. When opening the worksheet, there is a noticeable delay before becoming active for the user. Is there a way to use an array for this? </p>
  
  <pre><code>Dim ws As Worksheet
  Dim rng As Range
  Dim ce As Range
  
  Set ws = ActiveSheet
  Set rng = Union(ws.Range("B4:B9"), ws.Range("E4:E9"), ws.Range("I4:I10"), ws.Range("B10"), ws.Range("A14:O425"))
  
  Application.ScreenUpdating = False
  ws.Unprotect Password:="mediate"
  For Each ce In rng
      ce.Select
      Selection.Locked = "False"
  Next ce
  
  ws.Protect Password:="mediate", UserInterfaceOnly:=True, AllowFormattingCells:=True
  Application.ScreenUpdating = True
  </code></pre>