• Arrays (97)

    Author
    Topic
    #1769976

    I have a worksheet with string data in column “A”, that I would like to load into an array. I know how to loop through the data and count the number rows (data elements), but am lost as to loading the elements into the array.

    Viewing 1 reply thread
    Author
    Replies
    • #1785258

      And then what?

    • #1785260

      You need to set up an array with

      Dim Names()

      then establish th enumber of elements in th ethe array and ReDim Names(No of Elements)

      You can then loop through your range and assign the values to the array elements something like :-

      For i = 1 to NoOfElements
      Names(i) = Range(FirstCell).Offset(i,0).value
      Next

    Viewing 1 reply thread
    Reply To: Arrays (97)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: