$FUNCNAME$
  SET()
$CATEGORY$
  SYSTEM,ENVIRONMENT,INFO
$SUMMARY$
   Inspect or change a system setting
$LANG_RU$
       .
$SYNTAX$
     SET(<nSpecifier>, [<expNewSetting>], [<lOpenMode>]) --> CurrentSetting
$LANG_RU$
     SET(<>, [<  >], [<  >])
		  -->   
$ARGUMENTS$
     <nSpecifier> is a numeric value that identifies the setting to be
     inspected or changed.  <nSpecifier> should be supplied as a manifest
     constant (see below).
     <expNewSetting> is an optional argument that specifies a new value
     for the <nSpecifier>.  The type of <expNewSetting> depends on
     <nSpecifier>.
     <lOpenMode> is a logical value that indicates whether or not files
     opened for the following settings, _SET_ALTFILE, _SET_PRINTFILE, _SET_EXTRAFILE
     should be truncated or opened in append mode.  A value of false (.F.)
     means the file should be truncated.  A value of true (.T.) means the file
     should be opened in append mode.  In either case, if the file does not
     exist, it is created.

     If this argument is not specified, the default is append mode.
$LANG_RU$
     <> -   ,   ,
        .   <> 
          (. ).

     <  >   , 
          .   <
      >     <>.

     <  >  ,  ,
       ,    :
     _SET_ALTFILE,_SET_PRINTFILE,_SET_EXTRAFILE
             .
      "" (.F.) ,      
      .  "" (.T.) ,    
        .   ,    ,
       .

            
     .
$RETURNS$
     SET() returns the current value of the specified setting.
$LANG_RU$
     SET()     .
$DESCRIPTION$
     SET() is a system function that lets you inspect or change the values of
     the xClipper system settings.  For information on the meaning and
     legal values for a particular setting, refer to the associated command
     or function.

     Use a manifest constant to specify the setting to be inspected or
     changed.  These constants are defined in a header file called Set.ch.
     This header file should be included at the top of any source file which
     uses SET().

     Set.ch also defines a constant called _SET_COUNT.  This constant is
     equal to the number of settings that can be changed or inspected with
     SET(), allowing the construction of a generic function that preserves
     all settings (see example below).

     Note:  The numeric values of the manifest constants in Set.ch are
     version-dependent and should never be used directly; the manifest
     constants should always be used.

     If <nSpecifier> or <expNewSetting> is invalid, the call to SET() is
     ignored.

     <PRE> Set Values Defined in Set.ch
     ------------------------------------------------------------------------
     Constant            Value Type     Associated Command or Function
     ------------------------------------------------------------------------
     _SET_EXACT          Logical        SET EXACT
     _SET_FIXED          Logical        SET FIXED
     _SET_DECIMALS       Numeric        SET DECIMALS
     _SET_DATEFORMAT     Character      SET DATE
     _SET_EPOCH          Numeric        SET EPOCH
     _SET_PATH           Character      SET PATH
     _SET_DEFAULT        Character      SET DEFAULT
     _SET_EXCLUSIVE      Logical        SET EXCLUSIVE
     _SET_SOFTSEEK       Logical        SET SOFTSEEK
     _SET_UNIQUE         Logical        SET UNIQUE
     _SET_DELETED        Logical        SET DELETED
     _SET_CANCEL         Logical        SETCANCEL()
     _SET_DEBUG          Numeric        ALTD()
     _SET_COLOR          Character      SETCOLOR()
     _SET_CURSOR         Numeric        SETCURSOR()
     _SET_CONSOLE        Logical        SET CONSOLE
     _SET_ALTERNATE      Logical        SET ALTERNATE
     _SET_ALTFILE        Character      SET ALTERNATE TO
     _SET_DEVICE         Character      SET DEVICE
     _SET_PRINTER        Logical        SET PRINTER
     _SET_PRINTFILE      Character      SET PRINTER TO
     _SET_MARGIN         Numeric        SET MARGIN
     _SET_BELL           Logical        SET BELL
     _SET_CONFIRM        Logical        SET CONFIRM
     _SET_ESCAPE         Logical        SET ESCAPE
     _SET_INSERT         Logical        READINSERT()
     _SET_EXIT           Logical        READEXIT()
     _SET_INTENSITY      Logical        SET INTENSITY
     _SET_SCOREBOARD     Logical        SET SCOREBOARD
     _SET_DELIMITERS     Logical        SET DELIMITERS
     _SET_DELIMCHARS     Character      SET DELIMITERS TO
     _SET_WRAP           Logical        SET WRAP
     _SET_MESSAGE        Numeric        SET MESSAGE
     _SET_MCENTER        Logical        SET MESSAGE
     ------------------------------------------------------------------------
     </PRE>

     Note:  _SET_EXTRAFILE and _SET_SCROLLBREAK have no corresponding
     commands.  _SET_EXTRAFILE lets you specify an additional alternate file,
     and _SET_SCROLLBREAK lets you toggle the interpretation of Ctrl+S.
$LANG_RU$
     SET()   ,    
         xClipper.  
             
            .

     ,    ,  
       .     
      Set.ch.

              
     ,   SET().

      Set.ch   ,  _SET_COUNT. 
      -  ,     
         SET(),   
     ,    (. ,  ).

     :
           Set.ch  
     ,       . 
        .

        <>  <  > 
     ,  SET() .

     <PRE>  ,   SET()     Set.ch.
     ---------------------------------------------------------------------
                       
     ---------------------------------------------------------------------
     _SET_EXACT               SET EXACT
     _SET_FIXED               SET FIXED
     _SET_DECIMALS              SET DECIMALS
     _SET_DATEFORMAT          SET DATE
     _SET_EPOCH                 SET EPOCH
     _SET_PATH                SET PATH
     _SET_DEFAULT             SET DEFAULT
     _SET_EXCLUSIVE           SET EXCLUSIVE
     _SET_SOFTSEEK            SET SOFTSEEK
     _SET_UNIQUE              SET UNIQUE
     _SET_DELETED             SET DELETED
     _SET_CANCEL              SETCANCEL()
     _SET_DEBUG               ALTD()
     _SET_COLOR               SETCOLOR()
     _SET_CURSOR                SETCURSOR()
     _SET_CONSOLE             SET CONSOLE
     _SET_ALTERNATE           SET ALTERNATE
     _SET_ALTFILE             SET ALTERNATE TO
     _SET_DEVICE              SET DEVICE
     _SET_PRINTER             SET PRINTER
     _SET_PRINTFILE           SET PRINTER TO
     _SET_MARGIN                SET MARGIN
     _SET_BELL                SET BELL
     _SET_CONFIRM             SET CONFIRM
     _SET_ESCAPE              SET ESCAPE
     _SET_INSERT              READINSERT()
     _SET_EXIT                READEXIT()
     _SET_INTENSITY           SET INTENSITY
     _SET_SCOREBOARD          SET SCOREBOARD
     _SET_DELIMITERS          SET DELIMITERS
     _SET_DELIMCHARS          SET DELIMITERS TO
     _SET_WRAP                SET WRAP
     _SET_MESSAGE               SET MESSAGE
     _SET_MCENTER             SET MESSAGE
     ---------------------------------------------------------------------
     </PRE>
$EXAMPLES$
       In this example a user-defined function preserves or restores
	all global settings.  This function might be used on entry to a
	subsystem to ensure that the subsystem does not affect the state of
	the program that called it:

	#include "Set.ch"
	//

	FUNCTION SetAll( aNewSets )
	   LOCAL aCurrentSets[_SET_COUNT], nCurrent
	   IF ( aNewSets != NIL )   // Set new and return current
	      FOR nCurrent := 1 TO _SET_COUNT
		 aCurrentSets[nCurrent] := ;
		    SET(nCurrent, aNewSets[nCurrent])
	      NEXT
	   ELSE         // Just return current
	      FOR nCurrent := 1 TO _SET_COUNT
		 aCurrentSets[nCurrent] := SET(nCurrent)
	      NEXT
	   ENDIF
	   RETURN (aCurrentSets)
$LANG_RU$
           ,  
          .    
              , 
              :

       #include "Set.ch"
       //
       FUNCTION SetAll( aNewSets )
	  LOCAL aCurrentSets[_SET_COUNT], nCurrent
	  IF (aNewSets != NIL ) //     
	     FOR nCurrent := 1 TO _SET_COUNT
	     aCurrentSets[nCurrent] := SET(nCurrent, aNewSets[nCurrent])
	     NEXT
	  ELSE                  //   
	     FOR nCurrent := 1 TO _SET_COUNT
	     aCurrentSets[nCurrent] := SET(nCurrent)
	     NEXT
	  ENDIF
	  RETURN (aCurrentSets)
$SEEALSO$

$END$
