http://groups.google.com/group/google-web-toolkit/browse_thread/thread/8c708ac2da186d17/ca92d9d8f78a0e19
On Dec 9, 4:05 am, Appien <appienvanv...@gmail.com> wrote: > Hi folks, > > At the moment I'm having troubles with starting a file download using > GWT. In my application we have a Form object which contains all data > which should be stored on a PDF file. Currently my applications works > like this to generate the file and start the download. > > 1. Do a RPC call to store a form object in the session > 2. If succesfull, call servlet by a GET method > 3. Get the form object out of the session, genereate the pdf and write > the Response object > > However, this solutions fails due to the fact that during the calls 2 > sessions gets created. The first one when I do an RPC call to store > the form in the session. When the RPC call is finished the session > gets destroyed. The second session is created when I do a call to the > servlet. The servlet cannot find the stored Form object as the session > in which the Form object is stored is already destroyed. > > How can I handle the different created sessions on the server? > > As GWT cannot handle file download using RPC, an alternative solution > would be to create a tempory file. In this solution I would create a > RPC call which creates a file with an unique filename. When this file > is created, I call the servlet to get the file. Is this a nice > solution for this problem or is there a more nifty solution? > > Regards, -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.