[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
_evalPutParam()
Place a parameter in an EVALINFO structure
------------------------------------------------------------------------------
C Prototype
#include "item.api"
BOOL _evalPutParam(
EVALINFOP evalInfoP,
ITEM itmParam
)
Arguments
evalInfoP is the structure in which to add the parameter.
itmParam is the parameter to add to the structure.
Returns
TRUE if the operation was successful.
Description
The _evalPutParam() function allows you to place parameters in an
EVALINFO structure one at a time. Parameters are placed in the order
that they are passed (i.e., the first call to _evalPutParam() places the
first parameter, the second call places the second parameter, and so
on).
Note: If a particular evaluation does not require parameters, there
is no need to call this function at all, simply call _evalNew() and then
_evalLaunch().
Warning! Parameters in an EVALINFO structure should not be released
(via _itemRelease() or _evalRelease()) until the evaluation is performed
or the EVALINFO structure is no longer needed.
Examples
/*
* USERDO()
* --------
*/
CLIPPER userDO( void )
{
EVALINFO info;
USHORT uiParam;
ITEM retP;
/* Get evaluation expression */
if ( PCOUNT < 1 )
{
_ret();
return;
}
else
{
_evalNew( &info, _itemParam( 1 ) );
}
/* Get parameters */
for ( uiParam=2; uiParam <= PCOUNT; uiParam++ )
{
_evalPutParam( &info, _itemParam(uiParam) );
}
/* Launch evaluation information */
retP = _evalLaunch( &info );
/* Release ITEMs associated w/eval info */
_evalRelease( &info );
_itemReturn ( retP );
_itemRelease( retP );
return;
}
Files Library is CLIPPER.LIB, header file is Item.api.
See Also:
_evalLaunch()
_evalNew()
_evalRelease()
_itemRelease()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson