Title:
spreadsheetwrite autosize does not work to re-size columns with datetime values.
| View in TrackerStatus/Resolution/Reason: Closed/Fixed/
Reporter/Name(from Bugbase): / ext-user (Piyush Kumar Nayak)
Created: 05/27/2013
Components: Document Management, Office Integration
Versions: 11.0
Failure Type:
Found In Build/Fixed In Build: 284950 /
Priority/Frequency: Major / Some users will encounter
Locale/System: English,Japanese / Windows 7 SP1 64-bit
Vote Count: 0
Problem:
spreadsheetwrite autosize does not work to re-size columns with datetime values.
Method:
<cfset param_val = "true,false">
<cfset colList = "col1,col2,col3,col4,col5">
<cfset qryObj = QueryNew("#colList#")>
<cfset rowCount = 100>
<cfset QueryAddRow(qryObj, #rowCount#)>
<cfloop from="1" to="#rowCount#" index="r">
<cfset QuerySetCell(qryObj, "col1", "#now()#", r)>
<cfset QuerySetCell(qryObj, "col2", "2012-10-17 10:21:15.720", r)>
<cfset QuerySetCell(qryObj, "col3", "2012-10-17 19:10am", r)>
<cfset QuerySetCell(qryObj, "col4", "12-March-2013", r)>
<cfset QuerySetCell(qryObj, "col5", "jan-04-1989", r)>
</cfloop>
<cfloop list="#param_val#" index="i">
<cfset xlObj = spreadsheetNew("testsheet_xlsx", "true")>
<cfset spreadsheetAddRows(xlObj, qryObj)>
<cfset spreadSheetWrite(xlObj, "#Expandpath("./")#test_#i#.xlsx", "password", "true", "#i#")>
</cfloop>
Result:
a row from the content of the excel file test_true:
###### 2012-10-17 10:21:16 ###### ###### ######
Expected:
a row from the content of the excel file test_true:
27-05-2013 2012-10-17 10:21:16 17-10-2012 12-03-2013 04-01-1989
Workaround:
n/a
----------------------------- Additional Watson Details -----------------------------
Watson Bug ID: 3567818
Build Regressed: 290746
External Customer Info:
External Company:
External Customer Name:
External Customer Email:
Attachments:
Comments: