excel cell coloring

前端 未结 6 1794
刺人心
刺人心 2020-12-06 12:06

I am using c# to color particular cells of excel file. I am using:

Application excel = new Application();
Workbook wb = excel.Workbooks.Open(destPath);
 Work         


        
6条回答
  •  半阙折子戏
    2020-12-06 12:30

    Try something like that

    ws.Cells[row, clmn].Interior.Color = System.Drawing.ColorTranslator.ToOle(System.Drawing.Color.Red)
    

提交回复
热议问题