jsp导出excel身份证过长导致显示不正常自定义单元格格式解决方法

来源:互联网 发布:qsdd源码 编辑:程序博客网 时间:2024/06/04 07:45
<html><head></head><body><table> <tr>  <td>1</td>  <td style="mso-number-format:'/@';">10000000000001</td>  <td style="mso-number-format:'0/.00';">111111111111111</td> </tr>  <tr>  <td>1</td>  <td>10000000000001</td>  <td>11111111111111111111</td> </tr></table></body></html>

 

 

主要是 <td style="mso-number-format:'/@';"> 起作用

 

 

其他自定义单元格格式 样式

 

mso-number-format:"0"no decimalsmso-number-format:"0/.000"3 decimalsmso-number-format:"/#/,/#/#0/.000"comma with 3 decmso-number-format:"mm//dd//yy"date7mso-number-format:"mmmm/ d/,/ yyyy"date9mso-number-format:"m//d//yy/ h/:mm/ am//pm"d -t ampmmso-number-format:"short date"01/03/1998mso-number-format:"medium date"01-mar-98mso-number-format:"d/-mmm/-yyyy"01-mar-1998mso-number-format:"short time"5:16mso-number-format:"medium time"5:16 ammso-number-format:"long time"5:16:21:00mso-number-format:"percent"percent - two decimalsmso-number-format:"0%"percent - no decimalsmso-number-format:"0/.e+00"scientific notationmso-number-format:"/@"textmso-number-format:"/#/ ???//???"fractions - up to 3 digits (312/943)mso-number-format:"/0022£/0022/#/,/#/#0/.00"£12.76mso-number-format:"/#/,/#/#0/.00_ /;/[red/]/-/#/,/#/#0/.00/ "

2 decimals, negative numbers in red and signed
(1.56 -1.56)

原创粉丝点击