Spire.Doc is a professional Word .NET library specifically designed for developers to create, read, write, convert and print Word document files. Get free and professional technical support for Spire.Doc for .NET, Java, Android, C++, Python.

Tue May 14, 2024 9:47 pm

How can I create bullets with the middle dash symbol? example:

- This is a custom bullet


With the following code it gives me another different symbol:
Code: Select all
 ListStyle bulletedListStyle = new ListStyle(strDocument, ListType.Bulleted);
 bulletedListStyle.Name = "bulltedStyle";
 bulletedListStyle.Levels[1].BulletCharacter = "-";
 strDocument.ListStyles.Add(bulletedListStyle);


I thank you for your response

PolloKulos
 
Posts: 11
Joined: Sun Mar 28, 2021 3:23 am

Wed May 15, 2024 3:56 am

Hi,

Thank you for your message.
Please note that the index of Levels starts from 0. Please refer to the following code to test. If there's still any issue, just feel free to contact us again.

bulletedListStyle.Levels[0].BulletCharacter = "-";

Sincerely,
Doris
E-iceblue support team
User avatar

Doris.Liu
 
Posts: 460
Joined: Mon Nov 07, 2022 8:10 am

Return to Spire.Doc

cron