long ZCslCallEx( /* call function (extended) */
ZCslHandle aHandle, /* CSL handle */
const char *aFileName, /* file/module caller belongs to */
const char *aFuncName, /* function name */
long aArgCount, /* # of arguments following */
char *aParam[], /* parameter list. NULL if no args */
long aSize[] /* parameter size list. NULL if no args */
);
Calls any CSL, C or C++ function known to CSL.
Parameters are supplied as pairs of char* and long. The long value is the size
of the corresponding argument. If it is -1 the parameter is considered a zero
terminated string. With this API it is possible to pass parameters containing
NUL chars.
Example:
static char *args[] = { "The quick brow fox", "5", "\33[c\0\1" };
static long sze[] = { -1, -1, 5 };
long errs, size;
char buf[40];
/* call strSubString */
errs = ZCslCallEx(csl, "MyProg.exe", "strSubString", sizeof(args)/sizeof(char*), args, sze);
if (errs) .... /* error handling */
/* retrieve result */
size = sizeof(buf);
errs = ZCslGetResult(csl, buf, &size);
if (errs) .... /* error handling */
|