How do I call CA-Clipper code from C? Can this even be done?
Date: 25-Nov-91
X-Contributors: Steve Larsen <76370.1532@compuserve.com>,
Jobst Hensiek <76656.1606@compuserve.com>
With versions prior to 5.2, you have to set up Clip's internal
EVAL stack properly with _xpushf() and _xpopf(). Afterwards,
call _xdo() to execute the CA-Clipper function. The whole thing is
undocumented, and it is discouraged by CA because it requires
the use of internal functions which are not guaranteed to remain
unchanged from one CA-Clipper version to the next. Most people
spend weeks poking around the symbol tables to get this to work.
CA-Clipper 5.2e's well-documented Item API (Application Programming
Interface) allows you to evaluate CA-Clipper expressions, and view
or change CA-Clipper variables, directly from C code. You can
request this documentation free from CA if you have purchased
CA-Clipper 5.2e.
It appears to be very difficult if not impossible to call
CA-Clipper code successfully from within a C "main" program. The
environment must be CA-Clipper calling C calling CA-Clipper for
this stunt to work.