以下是一些示例的代码片段:
theSheet = SpreadsheetNew("Rates","True"); SpreadsheetAddRow(theSheet,"4A,4B,4C,4D,4E,4F,4G,4H,4I,4J"); SpreadsheetAddRow(theSheet,"4K,4L,4M,4N,4O,4P,4Q,4R,4S,4T"); SpreadsheetAddRow(theSheet,"4U,4V,4W,4X,4Y,4Z,4D4,4F4");
和
<cfheader name="content-disposition" value="attachment; filename=#GetTickCount()#.xlsx"> <CFHEADER NAME="Expires" VALUE="#now()#"> <cfcontent type="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" variable="#SpreadsheetReadBinary(theSheet)#"/>
问题是“4D”和“4F”(而不是其他人)失去了’D’和’F’并被格式化为数字.
我试过这个:
formatText = StructNew(); formatText.dataformat="@"; SpreadsheetFormatColumns(theSheet,formatText,"1-10");
我确认这将Excel中的格式设置为“文本”,但现在我只看到文本格式单元格中的数字4!我也试过使用’字符,但是当它在Excel中打开时,它只显示’而不是字面化单元格.
这很奇怪;有谁知道发生了什么?
似乎解决方法是将单元格公式设置为文字“4D”.
theSheet = SpreadsheetNew("Rates",4J"); SpreadsheetSetCellFormula(theSheet,"""4D""",1,4); SpreadsheetSetCellFormula(theSheet,"""4F""",6); SpreadsheetAddRow(theSheet,4F4");
我仍然不知道为什么会发生这种情况,但我的想法是SpreadsheetAddRow()和SpreadsheetSetCell()将4D和4F解释为数字并解释D和F以及代表Double和Float的后缀,并在之后将它们删除转换.
您可以转到https://bugbase.adobe.com/index.cfm将错误提交给Adobe.
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。