Skip to main content

List

Remove all lists from the main sub-document

var mainSubDoc = richEdit.document.subDocuments.main;
richEdit.document.lists.deleteNumeration(mainSubDoc, mainSabDoc.interval);

Customize a bullet format

// creates and customizes a new bullet list
var list = richEdit.document.lists.create(DevExpress.RichEdit.ListType.Bullet);
var listProps = list.levelProperties;
listProps[0].displayFormatString = '-';
list.levelProperties = listProps;
// applies the list style to the current paragraph
var paragraph = richEdit.document.paragraphs.find(richEdit.selection.active)[0];
paragraph.addToList(list, 0);

Number a list with roman numerals

// creates and customizes a new number list
var list  = richEdit.document.lists.create(DevExpress.RichEdit.ListType.Number);
var listProps = list.levelProperties;
listProps[0].format = DevExpress.RichEdit.ListLevelFormat.UpperRoman;
list.levelProperties = listProps;
// applies the list style to the current paragraph
var paragraph = richEdit.document.paragraphs.find(richEdit.selection.active)[0];
paragraph.addToList(list, 0);