Removing hotspots from body using Lotus notes C API

107 views Asked by At

I am trying to remove hotspots from Note body using C API. I know one way to do this:

1) NSFNoteOpen(hDb, noteId, 0 /*NO FLAGS*/, &hNote);
2) Enumerate allTYPE_COMPOSITE items, Keep appending all CD records in separate buffer except records between SIG_CD_HOTSPOTBEGIN and SIG_CD_HOTSPOTEND
3) remove this item and append newly created item.
4) NSFNoteUpdate(hNote, UPDATE_FORCE);

But problem is that, all Rich text infomations is lost

Is it possible to achieve the same when note is opened with OPEN_RAW_MIME flag? There are no TYPE_COMPOSITE items in the note in this case.

Thanks

1

There are 1 answers

0
Richard Schwartz On

You need to determine the type of the Body field and act accordingly. I.e., if the Body is stored as TYPE_COMPOSITE, you already know what to do. But if the Body is stored as TYPE_MIME_PART, you need to use the Notes C API calls whose names all start with "MIME". You can find these functions listed in the Notes C API Reference. Here are a couple of blog posts that talk a bit about some related subjects.