Aspose.Words.Examples.CSharp.Programming_Documents.Working_with_Tables.ApplyFormatting.ModifyRowFormatting C# (CSharp) Method

ModifyRowFormatting() private static method

Shows how to modify formatting of a table row.
private static ModifyRowFormatting ( string dataDir ) : void
dataDir string
return void
        private static void ModifyRowFormatting(string dataDir)
        {
            // ExStart:ModifyRowFormatting
            Document doc = new Document(dataDir + "Table.Document.doc");
            Table table = (Table)doc.GetChild(NodeType.Table, 0, true);
            
            // Retrieve the first row in the table.
            Row firstRow = table.FirstRow;
            // Modify some row level properties.
            firstRow.RowFormat.Borders.LineStyle = LineStyle.None;
            firstRow.RowFormat.HeightRule = HeightRule.Auto;
            firstRow.RowFormat.AllowBreakAcrossPages = true; 
            // ExEnd:ModifyRowFormatting
            Console.WriteLine("\nSome row level properties modified successfully.");
        }
        /// <summary>