1

I create a word document the DocX project.

I need to set my paragrpah right-to-left but I don't know what should I do?

string fileName = @"D:\Users\John\Documents\DocXExample.docx";

// Create a document in memory:
var doc = DocX.Create(fileName);

// Insert a paragrpah:
doc.InsertParagraph("This is my first paragraph");

// Save to the output directory:
doc.Save();

// Open in Word:
Process.Start("WINWORD.EXE", fileName);
4

1 回答 1

3

我终于发现,我们应该使用类似的东西:

        Paragraph p = doc.InsertParagraph(subject);
        p.Direction=Direction.RightToLeft;
于 2013-11-24T12:18:30.417 回答