Excel Import: Server Error: An error has occurred while handling the request

1
I am having trouble with Excel import. I have scanned previous forum questions and have not come accross the same issue. When I am importing a Excel File I get a pop up box that states: Server Error: An error has occurred while handling the request I have tried to import the simplest file but I still get the same error. This is my Stack Trace: An error has occurred while handling the request. [User 'SysAdmin' with roles 'SystemAdministrator'] java.util.concurrent.ExecutionException: com.mendix.core.CoreException: Exception occurred in action 'Microflow [ExcelImporter.IVKSaveContinueCreateTemplateFromDoc]', all database changes executed by this action were rolled back at java.util.concurrent.FutureTask$Sync.innerGet(FutureTask.java:222) at java.util.concurrent.FutureTask.get(FutureTask.java:83) at lU.execute(SourceFile:60) at ju.a(SourceFile:299) at ju.a(SourceFile:230) at ju.processRequest(SourceFile:174) at fC.a(SourceFile:71) at com.mendix.core.MxRuntime.processRequest(SourceFile:916) at com.mendix.m2ee.server.handler.RuntimeHandler.handle(RuntimeHandler.java:42) at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:113) at org.eclipse.jetty.server.Server.handle(Server.java:334) at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:559) at org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.java:1007) at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:747) at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:209) at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:406) at org.eclipse.jetty.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:462) at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:436) at java.lang.Thread.run(Thread.java:662) Caused by: com.mendix.core.CoreException: Exception occurred in action 'Microflow [ExcelImporter.IVKSaveContinueCreateTemplateFromDoc]', all database changes executed by this action were rolled back at com.mendix.core.actionmanagement.CoreAction.d(SourceFile:553) Caused by: com.mendix.core.CoreException: Exception occurred in microflow 'ExcelImporter.IVKSaveContinueCreateTemplateFromDoc' for activity 'Get the columns from the template document', all database changes executed by this microflow were rolled back at kP.b(SourceFile:251) Caused by: com.mendix.core.CoreException: Document could not be read, because: No headers could be found on sheet: 0 on row nr: 0 at excelimporter.reader.readers.ExcelXLSReader.getHeaders(ExcelXLSReader.java:127) Caused by: com.mendix.core.CoreException: No headers could be found on sheet: 0 on row nr: 0 at excelimporter.reader.readers.ExcelXLSReader.getHeaders(ExcelXLSReader.java:105) at excelimporter.reader.ExcelImporter.getColumns(ExcelImporter.java:54) at excelimporter.actions.GetHeaderInformationFromExcelFile.executeAction(GetHeaderInformationFromExcelFile.java:42) at excelimporter.actions.GetHeaderInformationFromExcelFile.executeAction(GetHeaderInformationFromExcelFile.java:20) at com.mendix.systemwideinterfaces.core.UserAction.execute(SourceFile:49) at com.mendix.core.actionmanagement.CoreAction.call(SourceFile:473) at it.b(SourceFile:155) at com.mendix.core.Core.execute(SourceFile:191) at hi.a(SourceFile:70) at kP.a(SourceFile:66) at eO.executeAction(SourceFile:96) at com.mendix.systemwideinterfaces.core.UserAction.execute(SourceFile:49) at com.mendix.core.actionmanagement.CoreAction.call(SourceFile:473) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662)
asked
2 answers
2

It seems your sheet has no headers (or you are locking it with excel).

Try to create a template from an excel file and read that same excel file. That should always work.

answered
1

I must apologise. I made two mistakes that lead to all my Excel Import issues.

1) I used the Excel5.0/95 Workbook .xls format (which is not compatible)

2) There where hidden sheets which were being read which did not have headers etc.

Thanks for the help

Allistair

answered