NPOI 设置样式为粗体

CellStyle style = hssfworkbook.CreateCellStyle();
Font f = hssfworkbook.CreateFont();
f.Boldweight = (short)FontBoldWeight.BOLD;
style.SetFont(f);
sheet1.GetRow(rowIdx).GetCell(colIdx).CellStyle = style;
posted @ 2017-02-21 14:41  a14907  阅读(9223)  评论(0)    收藏  举报