teamcfadvance / cfspreadsheet-railo

My Railo Extension provider including CFPOI (<cfspreadsheet>)
24 stars 16 forks source link

Null error when using alignment with SpreadsheetFormatCell #17

Closed Leigh- closed 13 years ago

Leigh- commented 13 years ago

Bug/Request Using any alignment value with SpreadsheetFormatCell produces a null error. Also, a null error occurs if the cell does not exist yet.

Code

sheet = SpreadsheetNew(); format = { alignment="center" }; // currently, must create the cell first to avoid error SpreadsheetSetCellValue(sheet,"test", 1, 1); SpreadsheetFormatCell(sheet, format, 1, 1);

Error Railo 3.2.1.000 Error (expression) Message No matching property [CENTER] found in [org.apache.poi.hssf.usermodel.HSSFCellStyle] Stacktrace The Error Occurred in C:\dev\railoExpressClean\webroot\WEB-INF\railo\components\org\cfpoi\spreadsheet\Spreadsheet.cfc: line 1951

1949: <cfset cellStyle.setAlignment(Evaluate("cellStyle." & "ALIGN_" & UCase(StructFind(arguments.format, setting)))) />
1950: <cfelse>
1951: <cfset cellStyle.setVerticalAlignment(Evaluate("cellStyle." & UCase(StructFind(arguments.format, setting)))) />
1952: </cfif>
1953: </cfcase>
Leigh- commented 13 years ago

Closed by commit andyj/RailoExtensionProvider@692ae8f2f1cdda0ad643