We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Default font for Paragraph in generating documents

Hi,


I’m using the aspose dlls for the generating the word documents.

But I’m having an issue with the default paragraph font as it is always turning to the default font “Times New Roman”.

I’ve also tried with the Aspose.word.style.name=“Calibri” to set the default font to calibri, but no luck.

Can any one please guide me the way to change the default font from the Times new roman to any other.


Thanks in advance.

Regards,
Gabriel.

Hi Gabriel,


Thanks for your inquiry. You can use the following code to change the font of the paragraph break character:

foreach (Paragraph para in doc.GetChildNodes(NodeType.Paragraph, true))
para.ParagraphBreakFont.Name = "font name";

I hope, this helps.

Best regards,