[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
_itemPutL()
Place a logical value into an item
------------------------------------------------------------------------------
C Prototype
#include "item.api"
ITEM _itemPutL(
ITEM itmLogic,
BOOL bValue
)
Arguments
itmLogic is the item in which you want to place the logical value.
If itmLogic is NULL, _itemPutL() will create a new item.
bValue is the logical (boolean) value to place into the item. As
with C, zero represents FALSE, and nonzeros represent TRUE.
Returns
A new item reference containing the logical value passed.
Description
The _itemPutL() function allows you to place a logical value into an
item. Note that if the first parameter passed to _itemPutL() is NULL,
_itemPutL() will create a new item and place the logical value lValue in
that item. The data contained in itmLogic is released to SVOS for
garbage collection.
Caution! Do not assume that the address in itmLogic will be the
same address returned by _itemPutL().
Examples
/*
*
* IsDouble( nNumber ) -> lIsIt
*
*
* Returns true if the number passed is
* internally represented as a double.
*/
CLIPPER IsDouble( void )
{
ITEM itmRet, itmNum;
itmRet = _itemPutL( NULL, FALSE );
if (PCOUNT > 0)
{
itmNum = _itemParam( 1 );
if (_itemType( itmNum ) & DOUBLE)
itmRet = _itemPutL( itmRet, TRUE );
_itemRelease( itmNum );
}
_itemRelease( _itemReturn( itmRet ) );
return;
}
Files Library is CLIPPER.LIB, header file is Item.api.
See Also:
_itemGetL()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson