I don't know of any methods in the API for this, so I think you need to write your own method that iterates through the array checking for null references (if the array holds object references) or zeros (if it holds primitives).
"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award." ~Joe Strummer sscce.org
It's not hard. All you need is a single int that is initially set to zero. Every time something gets added to the array, then increment the count. When something is removed, decrement the count. Then the only thing one needs to remember is that when the Array has one thing in it, it is actually at index 0, and your count index will be one. [ November 26, 2005: Message edited by: C Clites ]
Note: If the array holds object references, then checking for null is probably okay. But if the array holds primitive values, then you need to be careful to define what "no item" really means, because the default initialization of zero (or false) might be a perfectly valid assignment.
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com