We Have a requirement where the user exports and excel file We process that excel file in the server and update the excel and send it back to the user.
How to do this. I see some api related to export in
com.isomorphic.datasource.DSResponse but not sure how to do. Please send some example or throw some pointers.
For export to Excel (which is partly similar) we use Apache POI. POI can also parse an uploaded Excel spreadsheet, and allows you to modify it in memory.
DSResponse response = dsRequest.execute();
boolean isAExport = dsRequest.getExportResults();
List list = response.getDataList();
response.setData(outputList);
return response;
Using com.google.gwt.user.server.rpc.RemoteServiceServlet; to check, and set the current status of export is useful by overriding isSearchComplete(String operationId) and markSearchStarted(String operationId, String localeDatePattern)
Same approaches apply as for any binary download - the most straightforward is a servlet that streams the file back, which you reference by setting window.location to the URL of the servlet.