You could leave out NumberOfElements all together.

Code:
Private Sub DoStuff()
    Dim MyArray() As String
    Dim MyString As String
    Dim X As Integer

'This could be any FQDN so it is not safe to
'assume a specific number of elements
    MyString = "myhost.mysubdomain.mydomain.myrootdomain" 
    MyArray() = Split( MyString, "." )

    For X = 0 To UBound(MyArray)
        DoMoreStuff
    Next X

End Sub
Sunny