This week's book giveaway is in the Agile and other Processes forum. We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line! See this thread for details.
Hi I have follwoing code in servlet/action class. BinaryView docBinaryView =(BinaryView)documentInstance1.getView(OutputFormatType.XLS); response.setContentType("application/vnd.ms-excel"); response.setHeader("Content-Type", "application/vnd.ms-excel"); response.setDateHeader("expires", 0); docBinaryView.getContent(response.getOutputStream()); return mapping.findForward(null);
I checked with API documentation for class OutputFormatType and there is no constant variable called OutputFormatType.XLS but it has OutputFormatType.EXCEL
Thats True prabhu I too saw that link.But actually the implementation is xls only as when I say OutputFormatType. there is no EXCEL but xls.
The problem is If i open this in a new window I only get that error but if i try to open this excel in parent.I get same error dialog box but latter the excel opens. So I see problem some where else.
nitin singh
Greenhorn
Joined: Nov 07, 2006
Posts: 22
posted
0
Prabhu same code I use for pdf generation just chnage the content type to pdf and it runs fine .. I really wonder how the say EXCEL in the documentaion actually its exl.