Results 1 to 16 of 16

Thread: [RESOLVED]UBound giving subscript out of range

Threaded View

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jan 2005
    Posts
    21

    Resolved [RESOLVED]UBound giving subscript out of range

    I have an array
    Dim A() As String

    this is initially not initialized so I do this in a function (this function is called multiple tiles)
    Max = Ubound(A)

    If Max = 0 Then
    Redim A(Max+1,Max+10) As String
    End IF

    This UBound gives me a error saying Subscript out of range. How can I check if a array is initialized previously or not. It works if the array had some value but fails first time.
    Last edited by mysticmusician; Feb 20th, 2005 at 12:05 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width