Free Web Hosting Provider - Web Hosting - E-commerce - High Speed Internet - Free Web Page
Search the Web

MW-Menu

 

Free Visual BASIC Newsletter

Features

Tips

Sample Code

Newsletters

Products

ActiveX

Cool Links

 

 

 

 

 

 

 

Determine Whether An Array Is Empty

Here is a very simple function to check if an array is empty of not. If empty then 1 will be returned, else 0 will be returned if it is not empty.

Public Function ArrayEmpty(vaArray As Variant) As Long

On Error GoTo ErrSub

Dim lResult As Variant

lResult = vaArray(LBound(vaArray))

ArrayEmpty = 0

Exit Function

ErrSub:

If Err.Number = 9 Then ArrayEmpty = 1

End Function

Home

___________________________________________

Send Bugs, comments to the webmaster at webmaster@mwe.8m.com

Terms of Use

© 1999 MW Software, all rights reserved