[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
MEMORY()
Determine the amount of available free pool memory
------------------------------------------------------------------------------
Syntax
MEMORY(<nExp>) --> nKbytes
Arguments
<nExp> is a numeric value that determines the type of value MEMORY()
returns as follows:
MEMORY() Argument Values
------------------------------------------------------------------------
Value Meaning
------------------------------------------------------------------------
0 Estimated total space available for character values
1 Largest contiguous block available for character values
2 Area available for RUN commands
------------------------------------------------------------------------
Returns
MEMORY() returns an integer numeric value representing the amount of
memory available, in one -kilobyte increments.
Description
MEMORY() is an environment function that reports various states of free
pool memory. (Free pool is the dynamic region of memory that stores
character strings and executes RUN commands.)
Examples
. This example uses MEMORY() before a RUN command to determine
if there is enough memory available to execute the external program:
#define MEM_CHAR 0
#define MEM_BLOCK 1
#define MEM_RUN 2
//
IF MEMORY(MEM_RUN) >= 128
RUN MYPROG
ELSE
? "Not enough memory to RUN"
BREAK
ENDIF
Files Library is CLIPPER.LIB.
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson