Microsoft Foundation Classes (mfc.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
CObArray::GetUpperBound
CObArray                                    Up Contents Index Back
──Microsoft Foundation Classes──────────────────────────────────────────────
 
  int GetUpperBound() const;
 
  Remarks
 
  Returns the current upper bound of this array. Because array indexes are
  zero-based, this function returns a value 1 less than GetSize.
 
  The condition GetUpperBound() = -1 indicates that the array contains no
  elements.
 
  Example
 
  CObArray array;
 
  array.Add( new CAge( 21 ) ); // Element 0
  array.Add( new CAge( 40 ) ); // Element 1
  ASSERT( array.GetUpperBound() == 1 ); // Largest index
 
 
  See Also
 
  CObArray::GetSize, CObArray::SetSize
 
 
                                     -♦-