Hi David,
Thanks for your inquiry.
By default the text in a th element is bold and centered while the text in a td element is regular and left-aligned. Please see the following code snippet for the desired custom formatting:
Document
doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);
StringBuilder sb = new StringBuilder();
sb.Append("");
sb.Append("");
sb.Append("<th align=‘Left’>Month");
sb.Append("<th align=‘Left’>Savings");
sb.Append("
");
sb.Append("");
sb.Append(“
January | ”);
sb.Append("
$100 | ");
sb.Append("
");
sb.Append("
");
builder.InsertHtml(sb.ToString());
doc.Save(@“C:\test\toHTML.docx”);
I hope, this will help.
Best Regards,