网上查了点资料,POI的设置背景色必须与另外一个设置结合起来 headStyle.setFillPattern(HSSFCellStyle.SOLID_FOREGROUND); headStyle.setFillForegroundColor(HSSFColor.RED.index); 就可以了!