我很难在将数据从数据库导出到Excel电子表格时正确显示帐号。一家公司的帐号正确显示。但是,其他人没有。用户必须双击单元格以查看整个帐号。我已经Google了这个问题,并没有我尝试过的解决方案。导出到Excel不能正确显示数字
<cfsetting enablecfoutputonly="Yes">
<cfsavecontent variable="sTest">
<cfoutput>
<table>
<tr><th align="center">ATTUID</th>
<th>Company Name</th>
<th align="center">Account Number </th>
<th align="center">Total Past Due Balance</th>
<th align="center">Date Sent</th>
</tr>
<cfloop query="returnQuery">
<tr><td>#attuid#</td>
<td>#companyname#</td>
<td>#AccountNum4#</td>
<td>#totalpastdue#</td>
<td>#dateformat(posted)# #timeformat(posted, "h:mm tt")#</td>
</tr>
</cfloop>
</table>
</cfoutput>
</cfsavecontent>
<cfcontent type="application/vnd.msexcel">
<cfheader name="Content-Disposition" value="inline; filename=export.xls">
<cfoutput>#sTest#</cfoutput>
你是怎么做出口的?使用CF9电子表格功能,html(即psuedo-excel),...? – Leigh 2010-08-03 12:47:40
这里是输出。#sTest# –
user281867
2010-08-03 16:17:08