Function : Item (Field)

NSFItemCreateTextList - Append a TYPE_TEXT_LIST item to a note.
----------------------------------------------------------------------------------------------------------

#include <nsfnote.h>

STATUS LNPUBLIC NSFItemCreateTextList(
NOTEHANDLE note_handle,
const char far *item_name,
const char far *item_text,
WORD text_len);

Description :

This function takes a handle to an open note, the name for the text list item you wish to append , the text you wish to have stored as the FIRST entry in the list and the length of that text string. If an Item of that name already exists, it is first deleted and then the new value is appended with the same item name.

Note: NSFItemAppendTextList sets the ITEM_SUMMARY flag in the item. Items with the ITEM_SUMMARY flag set are stored in the note's summary buffer. These items may be used in view columns, selection formulas, and @functions. API program may read the summary buffer without opening the note. The maximum size of the summary buffer is 32K per note. If you append more than 32K bytes of data in items that have the ITEM_SUMMARY flag set, NSFItemAppendTextList will succeed, but NSFNoteUpdate will return ERR_SUMMARY_TOO_BIG. To avoid this, decide which fields are not used in view columns, selection formulas, or @ functions. Append these "non-computed" fields to the document using NSFItemAppend without setting the ITEM_SUMMARY flag in the item_flags argument.

Parameters :

Sample Usage :


  /* Create, populate, and store Item of TYPE_TEXT_LIST in  */
  /* in-memory copy of Note.                                */

 if (error_status = NSFItemCreateTextList(note1_handle,
                                         TEXT_LIST_ITEM,
                                         SOME_TEXT1,
                                         strlen(SOME_TEXT1)))
      goto Exit;


See Also :

NSFItemAppendTextList
----------------------------------------------------------------------------------------------------------