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 5.3 . Technical Reference - <b>addfield()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 addField()
 Add a column (field) to the work area
------------------------------------------------------------------------------
 .Prototype

     ERRCODE addField(
                          AREAP wa,
                          LPDBFIELDINFO lpdbFieldInfo
                        )

 Arguments

     wa is a pointer to self.

     lpdbFieldInfo is a pointer to a structure containing information
     about a column in the work area.

 Description

     addField() adds a column specified by lpdbFieldInfo to the wa work area.

 Default Behavior

     addField() inserts the column referred to by lpdbFieldInfo into the data
     table referenced by the AREA structure.  The new column is added to the
     end of the wa->lpFields structure.  wa->uiFieldCount is updated to
     reflect the addition.

     Note:  Call setFieldExtent() prior to adding fields to the AREA
     structure.  setFieldExtent() sizes and clears the wa->lpFields
     structure, readying it for use.

     Warning!  wa->uiFieldCount must be less than wa->uiFieldExtent
     or an assertion error will be raised.

 Implementation Notes

     .  Most implementations should use the default behavior for
        addField().  However, if you change the addField() implementation, be
        aware of the order imposed on adding fields to the work area
        structures.

 Files  Header file is Rdd.api.


See Also: AREA DBFIELDINFO createFields() setFieldExtent()

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