Excel12 vs Excel4

Excel12 and Excel12v ensure backwards compatibility with Excel 11 (2003) and earlier.


Excel12

This is a callback function that allows the DLL to call Excel.
Excel 2007 and later.
uese the XLOPER12 data structure
uese UNICODE based strings


int Excel12(int iFunction, 
            xloper12 *pxRes,
            int iCount,
            xloper12 *pxModuleText,
            xloper12 *pxProcedure,
            xloper12 *pxTypeText,
            xloper12 *pxFunctionText,
            xloper12 *pxArgumentText,
            xloper12 *pxMacroType,
            xloper12 *pxCategory,
            xloper12 *pxShortcutText,
            xloper12 *pxHelpTopic,
            xloper12 *pxFunctionHelp,
            xloper12 *pxArgumentHelp1,
            ..)

iFunction - xlfRegister
pxRes - A pointer that will hold the result
iCount - The number of arguments that are being passed in
pxModuleText -
pxProcedure -
pxTypeText -
pxFunctionText -
pxArgumentText - (Optional)
pxMacroType -
pxCategory -
pxShortcutText -
pxHelpTopic -
pxFunctionHelp -
pxArgumentHelp1 - Argument descriptions for each argument


All functions must be registered using the xlfRegister function from the C API


Excel12v

The Excel12 callback function provides arguments that are provided as a list of seperate arguments.
The Excel12v callback function provides arguments that are provided as an array.

int Excel12v(int iFunction, 
             xloper12 *pxRes,
             int iCount,
             xloper12 *pxArgs[])

iFunction - xlfRegister
pxRes - A pointer that will hold the result
iCount - The number of arguments that are being passed in
pxArgs - The array of arguments


LPXLOPER12

In most cases the prototype is written as:

int Excel12v(int iFunction, xloper12 *pRetVal, int count, xloper12 *args[]); 

but sometimes it is written as:

int Excel12v(int iFunction, LPXLOPER12 operRes, int count, xloper12 *args[]); 

This is just to represent that the argument is a pointer without having to include the asterisk (*)



XLOPER12 data type

This i s a multi-type data structure that can represent any type of worksheet data type.


FP12 data type

This is a two-dimensional floating point array structure that supports all the rows and columns



Excel4

Excel 2003 and earlier.
uese the XLOPER data structure
uses ASCII based strings


© 2025 Better Solutions Limited. All Rights Reserved. © 2025 Better Solutions Limited TopPrevNext