I am having trouble setting the background color on cells. I get the font to change colors, I just get WHITE cells when i attemp to change the background color. I also tried to add the color to the pallet and set it that way, and same results.
Here is an except from my code:
Dim wb As Workbook = New Workbook()
wb.Open(Server.MapPath(Request.ApplicationPath) & "\Excel\ExcelTemplate.xls")
Dim ogsheet As Worksheet = wb.Worksheets("LENDER")
Dim Sheet As Worksheet
Sheet.Cells.Item(1, 1).PutValue(HeaderStr)
Sheet.Cells.Item(1, 1).Style.Font.Color = (System.Drawing.Color.Blue)
Sheet.Cells.Item(1, 1).Style.BackgroundColor = (System.Drawing.Color.Red)
-=-=-=-=-=-=-=-=-----------=-=-=-=-=-==--==-=-=-=-=-=-=-=-
Also tried this:
wb.ChangePalette(System.Drawing.Color.FromArgb(Red, Blue, Green), 55)
Sheet.Cells.Item(row, col).Style.BackgroundColor = System.Drawing.Color.FromArgb( Red, Green, Blue)
My red blue green are int values.
Thanks,
michael