beginSection (RichTextItem - Java)

Inserts a section in a rich text item.

Note: This method is new with Release 6.5.

Defined in



public void beginSection(String title)
    throws NotesException
public void beginSection(String title, RichTextStyle titlestyle)
    throws NotesException
public void beginSection(String title, RichTextStyle titlestyle, ColorObject barcolor, boolean expand)
    throws NotesException


String title

The title of the section.

RichTextStyle titlestyle

The style of the title of the section. See RichTextStyle.

ColorObject barcolor

The color of the section bar. See ColorObject.

boolean expand
  • true expands the section
  • false (default) collapses the section


By default the insertion occurs at the end of the item. You can change the insertion point with beginInsert and endInsert.

You cannot create a section containing existing rich text. You must start the section with beginSection, append rich text, and end the section with endSection.

In an open document in edit mode (the NotesDocument via NotesUIDocument.Document), changes made to rich text will not appear on screen immediately as they would with fields of other types. There is no method to cause this update to occur. You must close and reopen the document to see changes.