Hi, All,
I use the codes as follow to set font style and paragraph style in VB.net, but it doesn’t work. Why?
document = New Aspose.Words.Document(fileName)
builder = New DocumentBuilder(document)
builder.Bold = 1
builder.Italic = 0
builder.Underline = 0
font.StrikeThrough = 0
builder.Font.Color = LColor.BackColor
builder.Font.Name = FontName
builder.ParagraphFormat.Alignment = ParagraphAlignment.Center
builder.Write(headContent)
builder.Document.Save(dFile)
I expected to add new Headers to the doc, and set the header in center alignment with the fontsize=20,fontcolor=red,fontBold=true,Fontname=“Arial”. but this codes didn’t work, so that I cannot use Words.dll to customize the fontstyle and paragraphStyle. What is the correct codes to implement this ?
Thanks for your demo in advance.
Cheng