0

Is there any way to get the style of a specific cell with open xml sdk and epplus?

Currently I'm getting the value in the following way:

currentWorksheet.Cells[nRowId, 3].Text.Trim();

In adittion to this I want if there is a background color, and a border.

ffffff01
  • 5,068
  • 11
  • 52
  • 61

1 Answers1

4

Try

currentWorksheet.Cells[nRowId, 3].Style;

Also:

currentWorksheet.Cells[nRowId, 3].Style.Fill.BackgroundColor;
currentWorksheet.Cells[nRowId, 3].Style.Border;
Vincent Tan
  • 3,058
  • 22
  • 21