When acedInvoke() returns RTNORM, this implies that the external function was called and returned successfully. It does not imply that the external function successfully obtained a result; to obtain this information, your program must inspect the result argument. If the external function is successful and is meant to return values, result points to a result-buffer list containing one or more values. If the external function failed, the result argument is set to NULL. The result argument is also NULL if the external function doesn't return a result.
The following sample code fragment checks the return value of an external function that is expected to return one or more result values:
struct resbuf *xfcnlist, *xresults; // Build the invocation list, xfcnlist. rc = acedInvoke(xfcnlist, &xresults); if (rc != RTNORM) { // Couldn't call the function—report this error (or even abort). return BAD; } if (xresults == NULL) { // Function was called but returned a bad result. return BAD; } // Look at return results and process them.