XLL+ Class Library (6.3)

CXlOper::Coerce

Convert an Excel range into an array of values, forcing a recalculation if necessary

int Coerce( );
int Coerce(
   const CXlRef& xlr
);
int Coerce(
   const CXlOper& xlo
);

Parameters

xlr

A valid reference to an Excel cell range.

xlo

A CXlOper containing at least one range reference.

Return Value

The result of the SDK call-back. xlretSuccess (0) indicates success. Other values indicate failure. A full list of return values can be found in Error Codes.

Remarks

This function fills the CXlOper object with the values contained in the cells referred to by the parameter. If there are no arguments, and the CXlOper currently contains a cell reference, then that reference will be used.

It is important to note that this function will fail under Excel 2003 and below if more than 64 kb of data is contained in the cell range. This is equivalent to about 5400 cells.

Example

CXlOper::Coerce() Example

Requirements

Header: xllplus.h

See Also

CXlOper Class | CXlOper Methods | CXlOper::SetValue()