Dear Sir
I could create a table with “builder.starttable” in my document.I want to set Table Direction Right to Left like MS Word in table properties but I don’t know how could I do it?
Please help me.
Thanks
Mehdi Mokhtari
Hi
Thanks for your request. I think that you should use RowFormat.Bidi property. For example see the following code example.
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);
// Set right to left
builder.RowFormat.Bidi = true;
builder.Font.Bidi = true;
builder.Font.LocaleIdBi = 1025;
// generate table
for (int i = 0; i < 5; i++)
{
for (int j = 0; j < 5; j++)
{
builder.InsertCell();
builder.Write("مرحبًا");
}
builder.EndRow();
}
builder.EndTable();
doc.Save(@"Test227\out.doc");
See the following link for more information.
https://reference.aspose.com/words/net/aspose.words.tables/table/bidi/
Hope this helps.
Best regards.