Initial Release 6

Function : Item (Field)
NSFItemQueryEx - Given BLOCKID of item, get all item and value info.
----------------------------------------------------------------------------------------------------------

#include <nsfnote.h>

void LNPUBLIC NSFItemQueryEx(
NOTEHANDLE note_handle,
BLOCKID item_bid,
char *item_name,
WORD return_buf_len,
WORD *name_len_ptr,
WORD *item_flags_ptr,
WORD *value_datatype_ptr,
BLOCKID *value_bid_ptr,
DWORD *value_len_ptr,
BYTE *retSeqByte,
BYTE *retDupItemID);

Description :

This function takes a handle to an open note, the BLOCKID of any item in that note, and the length of the text buffer that is to receive the item name. It returns all of the information that is typically required when appending an item using NSFItemAppendByBLOCKID: name, name length, flags, value data type, a BLOCKID associated with the value, and value length. This function and NSFItemQuery are the only direct means of obtaining item flags. The function NSFItemScan provides a callback routine which can also be used to obtain the contents of the item flags.

The BLOCKID values obtained using this function refer to memory within a note. This memory is managed by Domino and Notes, and should not be freed by the application.

Parameters :

Sample Usage :

/* Find Item in Note1 and print the ITEM_FLAGS */

  if ( error_status = NSFItemInfo(note1_handle, TEXT_ITEM,
                          strlen(TEXT_ITEM), &item_bid,
                          NULL, NULL, NULL))
      goto Exit;

  NSFItemQueryEx(note1_handle, item_bid,
               item_name_buf, name_buf_len,
               &item_name_len, &item_flags, &value_type,
               &value_bid, &value_len

     &retSeqByte, &retDupItemID);

  item_name_buf[item_name_len] = '\0';

  printf("Item %s has the following Item Flags set:\n",
         item_name_buf);

  if (item_flags & ITEM_SIGN)
      printf("\tITEM_SIGN\n");
  if (item_flags & ITEM_SEAL)
      printf("\tITEM_SEAL\n");
  if (item_flags & ITEM_SUMMARY)
      printf("\tITEM_SUMMARY\n");
  if (item_flags & ITEM_PROTECTED)
      printf("\tITEM_PROTECTED\n");


See Also :

NSFItemAppendByBLOCKID
----------------------------------------------------------------------------------------------------------