Test if array empty

what's the best way to test if an array in VBA is empty?
patriotpacerAsked:
Who is Participating?
 
Dale FyeConnect With a Mentor Commented:
if your array name is arrMyArray, then

if UBound(arrMyArray) = -1 then
    msgbox "array is empty"
Else
     msgbox "array is not empty"
endif
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.