Re: Generating spreadsheet to send to Client fails in 1.6

2013-08-26 Thread BrianWilliams
Not only did this work before, it has worked in every other web technology I've tried.  Can anyone on the Wicket team explain how Response handling changed in 1.5?  I am hoping there is a single line fix, like response.clearBuffer(), that will make my existing code work as it always has, rather

Re: Generating spreadsheet to send to Client fails in 1.6

2013-08-26 Thread Sven Meier
Please create a quickstart for Wicket 1.4.x so we can see how your solution worked. Thanks Sven On 08/26/2013 04:49 PM, BrianWilliams wrote: Not only did this work before, it has worked in every other web technology I've tried. Can anyone on the Wicket team explain how Response handling

Re: Generating spreadsheet to send to Client fails in 1.6

2013-08-02 Thread Sven Meier
Hi, I don't know how this worked for you in 1.4.x. But if you're just writing something into the response, how should Wicket know that it has to stop processing the request? Sven On 08/02/2013 04:24 AM, BrianWilliams wrote: Thank you but, did you see my original code? It's 1/2 as long as

Re: Generating spreadsheet to send to Client fails in 1.6

2013-08-02 Thread BrianWilliams
It simply redisplays the page and gives me the option to open or save the spreadsheet.  When I choose open, it's in another window so what I write directly to the response looks like an attachment to the browser. From: Sven Meier [via Apache Wicket]

Re: Generating spreadsheet to send to Client fails in 1.6

2013-08-01 Thread Martin Grigorov
Hi, See https://github.com/apache/wicket/blob/master/wicket-core/src/main/java/org/apache/wicket/markup/html/link/DownloadLink.java?source=cc#L167 for a simple example. On Thu, Aug 1, 2013 at 5:33 AM, BrianWilliams brianwilliams33...@yahoo.comwrote: Thank you again Paul. I'll look at

Re: Generating spreadsheet to send to Client fails in 1.6

2013-08-01 Thread BrianWilliams
Thank you but, did you see my original code?  It's 1/2 as long as the import section in your link.   I would like to simply write to the response, as I have in every other web technology (from Servlets and JSPs to Struts, JSF and .NET), AND Wicket prior to 1.5.    Perhaps somebody from the

Generating spreadsheet to send to Client fails in 1.6

2013-07-31 Thread BrianWilliams
Hello, I had code in Wicket 1.x that worked perfectly to dynamically generate a spreadsheet and send it to the user. I had to rewrite it for the new Response classes in 1.6: public void generateExcel(String filename, ListListlt;? extends Object dataList) { HSSFWorkbook myWorkBook =

RE: Generating spreadsheet to send to Client fails in 1.6

2013-07-31 Thread Paul Bors
I think you should also upgrade your Apache POI version and switch to .xlsx since the older format has a limit of about 65K records. Outside of that I suggest you use an IResourceStream instead of writing to your web response. Personally I use csv comma delimited since I don't do any magic beside

Re: Generating spreadsheet to send to Client fails in 1.6

2013-07-31 Thread BrianWilliams
Thank you Paul.  I appreciate the advice.  Regarding your suggestion to use IResourceStream, I wonder what the problem is with writing to the web response?  Is this simply something that is no longer supported in 6.x, even though it worked perfectly in 4.x?  I'd prefer to simply fix whatever

RE: Generating spreadsheet to send to Client fails in 1.6

2013-07-31 Thread Paul Bors
Well... Component.getResponse() calls getRequestCycle().getResponse() and you're then you're casting that Response object to a WebResponse and change it in the middle of wicket's processing it. Is simple to schedule your resource outside of wicket's normal flow right? Hence

Re: Generating spreadsheet to send to Client fails in 1.6

2013-07-31 Thread BrianWilliams
Thank you again Paul.  I'll look at scheduleRequestHandlerAfterCurrent and compare it.   And yes, you are right that IResourceStream is straightforward, but again I am blown away that something that worked perfectly pre6.x now requires a different strategy.  And no, I am not setting cookies or