Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a Table Cell Fill #32

Closed
PrzemyslawKlys opened this issue Jul 16, 2022 · 0 comments · Fixed by #30
Closed

Add a Table Cell Fill #32

PrzemyslawKlys opened this issue Jul 16, 2022 · 0 comments · Fixed by #30

Comments

@PrzemyslawKlys
Copy link
Member

using DocumentFormat.OpenXml.Wordprocessing;
using DocumentFormat.OpenXml;

namespace GeneratedCode
{
    public class GeneratedClass
    {
        // Creates an TableCell instance and adds its children.
        public TableCell GenerateTableCell()
        {
            TableCell tableCell1 = new TableCell();

            TableCellProperties tableCellProperties1 = new TableCellProperties();
            TableCellWidth tableCellWidth1 = new TableCellWidth(){ Width = "3116", Type = TableWidthUnitValues.Dxa };
            Shading shading1 = new Shading(){ Val = ShadingPatternValues.Clear, Color = "auto", Fill = "4472C4", ThemeFill = ThemeColorValues.Accent1 };

            tableCellProperties1.Append(tableCellWidth1);
            tableCellProperties1.Append(shading1);
            Paragraph paragraph1 = new Paragraph(){ RsidParagraphAddition = "001F2E94", RsidRunAdditionDefault = "001F2E94", ParagraphId = "037BA2FD", TextId = "77777777" };

            tableCell1.Append(tableCellProperties1);
            tableCell1.Append(paragraph1);
            return tableCell1;
        }


    }
}
@PrzemyslawKlys PrzemyslawKlys linked a pull request Jul 17, 2022 that will close this issue
28 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant