GetLinesCount

Paragraph.GetLinesCount 方法

获取段落中的行数。

public int GetLinesCount()

返回值

段落中的行数

示例

示例:

[C#]
using (Presentation pres = new Presentation())
{
    ISlide sld = pres.Slides[0];
    IAutoShape ashp = sld.Shapes.AddAutoShape(ShapeType.Rectangle, 150, 75, 150, 50);
    IParagraph para = ashp.TextFrame.Paragraphs[0];
    IPortion portion = para.Portions[0];
    portion.Text = "Aspose Paragraph GetLinesCount() Example";
    Console.WriteLine("Lines Count = {0}", para.GetLinesCount());
}

另见