A reference to a single item within an array CXlOper.
class CXlCell |
A CXlCell object represents a single item within a CXlOper array. It is created by calling CXlOper::Cell which, if it succeeds, returns a new CXlCell object.
You can use the CXlCell object to read and write the contents of the item within the CXlOper array. Many of the same methods as offered by CXlOper are available to CXlCell. Many are excluded, including methods that deal with arrays (CXlCell can only refer to a single cell), references (CXlCell must contain a value - it cannot contain a reference) and SDK calls.
Because Excel 2007 and earlier versions of Excel use different XLOPER structures, code that directly reads or writes the structure must be aware of which version of Excel it is using. The CXlCell class wraps these differences, so that you can ignore which version of Excel is being run.
The table below lists the data types supported by the CXlCell class.
Type | 'C' type | Description |
---|---|---|
xltypeNum | double | IEEE floating-point number (8 bytes) |
xltypeStr | LPSTR | Under Excel 2003 and below: an ASCII string (limited to 255 characters) |
xltypeStr | LPWSTR | Under Excel 2007 and above: a Unicode string (limited to 32,767 characters) |
xltypeBool | BOOL | Boolean |
xltypeInt | short int | Under Excel 2003 and below: a 16-bit integer |
xltypeInt | int | Under Excel 2007 and above: a 32-bit integer |
Header: xllplus.h
CXlCell Methods | xllplus.h | CXlConstCell | CXlOper::Cell | CXlOper