Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- CA-Clipper Tools . Books 1-3 - <b>envparam()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 ENVPARAM()
 Reads the entire DOS environment table into a string
------------------------------------------------------------------------------
 Syntax

     ENVPARAM() --> cEnvironment

 Returns

     ENVPARAM() returns a string that corresponds to the complete environment
     table.

 Description

     This function returns the entire DOS environment table.  The DOS CHR(0)
     delimiter, which follows each variable and its setting, is replaced with
     CR/LF.  This allows the returned string to work well with the CA-Clipper
     Tools string functions (especially the tokenizer).

 Note

     .  With the CA-Clipper function GETENV(), you can query
        individual parameters from the environment.  Initially, this may seem
        convenient, but there is a problem because no blanks are allowed
        before and after the '='.

 Example

     Read in the environment and analyze it:

     cVar  :=  ENVPARAM()                           // CR/LF as delimiter
     TOKENINIT (@cVar, CHR(13) + CHR(10),2)         // CR/LF as delimiter,
     skip 2
     DO WHILE .NOT. TOKENEND()
        Env  :=  TOKENNEXT(cVar)
        ? Env
     ENDDO


See Also: TOKENINIT() TOKENNEXT()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson