title: Getting 'SubScript Out of Range' Error in VBA when calling class Method
body: <p>I'm going to try to lay out this issue in as much detail as possible. Apparently I can't post images, as I am a New Member...So I will try to describe my situation as good as I possibly can.</p>
  
  <p>So, I am working with a custom class called "Shifts". I have this class declared and set up in a Class Module in VBA. I declare an instance of the "Shifts" class inside a normal Module and call it "Shift".</p>
  
  <pre><code>Dim Shift As New Shifts
  </code></pre>
  
  <p>My "Shifts" class has 4 variables (String Arrays):</p>
  
  <pre><code>Private ShiftMembers() As String
  Private ShiftCallSigns() As String
  Private ShiftAssignments() As String
  Private ShiftStatuses() As String
  </code></pre>
  
  <p>I have written a Sub within the class called "Clear" to clear the data in these variables (via ReDim):</p>
  
  <pre><code>Public Sub Clear()
      ReDim ShiftMembers(-1) As String
      ReDim ShiftCallSigns(-1) As String
      ReDim ShiftAssignments(-1) As String
      ReDim ShiftStatuses(-1) As String
  End Sub
  </code></pre>
  
  <p>Now, when I call the Clear Sub of the "Shifts" class (declared as "Shift"):</p>
  
  <pre><code>Shift.Clear 'This is called from within the Module.
  </code></pre>
  
  <p>i get Subscript out of range (Error 9). My class is declared at the very top of the module, outside of any methods or functions. The Clear() sub within my class is declared Public. I don't understand why I can't seem to access my Clear Sub properly. </p>
  
  <p>Any help would be greatly appreciated!</p>
  
  <p>-Rob</p>