Note
Access to this page requires authorization. You can try signing in or .
Access to this page requires authorization. You can try .
Word.ListBullet enum
- Package:
- word
Represents the bullet style in a list.
Remarks
Used by
Examples
// Link to full sample: https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/word/20-lists/organize-list.yaml
// Inserts a list starting with the first paragraph then set numbering and bullet types of the list items.
await Word.run(async (context) => {
const paragraphs: Word.ParagraphCollection = context.document.body.paragraphs;
paragraphs.load("$none");
await context.sync();
// Use the first paragraph to start a new list.
const list: Word.List = paragraphs.items[0].startNewList();
list.load("$none");
await context.sync();
// To add new items to the list, use Start or End on the insertLocation parameter.
list.insertParagraph("New list item at the start of the list", "Start");
const paragraph: Word.Paragraph = list.insertParagraph("New list item at the end of the list (set to list level 5)", "End");
// Set numbering for list level 1.
list.setLevelNumbering(0, Word.ListNumbering.arabic);
// Set bullet type for list level 5.
list.setLevelBullet(4, Word.ListBullet.arrow);
// Set list level for the last item in this list.
paragraph.listItem.level = 4;
list.load("levelTypes");
await context.sync();
});
Fields
| arrow = "Arrow" | Represents arrow bullet. |
| checkmark = "Checkmark" | Represents checkmark bullet. |
| custom = "Custom" | Represents custom bullet. |
| diamonds = "Diamonds" | Represents diamond bullet. |
| hollow = "Hollow" | Represents hollow bullet. |
| solid = "Solid" | Represents solid bullet. |
| square = "Square" | Represents square bullet. |
Collaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide.
Office Add-ins
Feedback
Was this page helpful?
