$FUNCNAME$
  FIELDBLOCK()
$CATEGORY$
  DATABASE,CODEBLOCK
$SUMMARY$
   Return a set-get code block for a given field
$LANG_RU$
          .
$SYNTAX$
     FIELDBLOCK(<cFieldName>) --> bFieldBlock
$LANG_RU$
     FIELDBLOCK(< >)  -->  
$ARGUMENTS$
     <cFieldName> is the name of the field to which the set-get block
     will refer.
$LANG_RU$
     < > -    .
$RETURNS$
     FIELDBLOCK() returns a code block that, when evaluated, sets (assigns)
     or gets (retrieves) the value of the given field.  If <cFieldName> does
     not exist in the specified work area, FIELDBLOCK() returns an empty
     block.
$LANG_RU$
     FIELDBLOCK()   ,   
       ,    
      .
$DESCRIPTION$
     FIELDBLOCK() is a database function that builds a code block.  When
     executed with an argument, the code block created by this function
     assigns the value of the argument to <cFieldName>.  When executed
     without an argument, the code block retrieves the value of <cFieldName>.

     Note that the specified field variable may not exist when the code block
     is created, but must exist before the code block is executed.
$LANG_RU$
     FIELDBLOCK() -   ,   , 
        EVAL()  ,  
      < >.      
        < >.

      < >      , 
             
         EVAL()    .
$EXAMPLES$
       This example compares FIELDBLOCK() to a code block created
	using the macro operator.  Note that using FIELDBLOCK() avoids the
	speed and size overhead of the macro operator:

	// Set-Get block defined using macro operator
	bSetGet := &amp;( "{ |setVal| IF( setVal == NIL,;
			FName, FName := setVal ) }" )
	// Set-Get block defined using FIELDBLOCK()

	// bSetGet created here is the functional
	// equivalent of bSetGet above
	bSetGet := FIELDBLOCK("FName")
$LANG_RU$
          FIELDBLOCK()   
           . , 
        FIELDBLOCK()      
          :

       //       
       bSetGet := &amp;("{ |setVal| IF(setVal == NIL, FName, FName := setVal)}")

       //      FIELDBLOCK()
       //        
       // bSetGet,  
       bSetGet := FIELDBLOCK("FName")
$SEEALSO$
  FIELDWBLOCK(),MEMVARBLOCK()
$END$
