Technically no. It's a limitation of the HTML spec. You could try the following hack (untested so dunno how practicle this is & what pitfalls you might enounter - as the lkml people say, here be dragons):
In your response, you could presumably return JSON objects which you can then eval in JSNI & use overlay types to provide more Java-friendly access to them. Additionally, if you were super-crazy, it might be possible to try & use the GWT RPC serializer to serialize the response on the server side & then somehow get the GWT de-serializer on the client to parse the result into "Java" objects. On Fri, Apr 24, 2009 at 9:38 PM, TimOnGmail <[email protected]> wrote: > > Hi all... > > I'm using FileUpload to upload a file to a servlet. > > The problem is, there can be a lot of different problems on the server > side (IOExceptions, format errors, etc.), and I want to get those back > to my GWT app. > > Problem is, it seems the FileUpload only reports back (via its Event > mechanism) that text of a "page" that is returned in the response. I > can't seem to get an error message, Exception object, status code, or > anything like that; just a page of HTML, text, etc. > > Does anyone know if there is any way to report back status, other than > return back some known text/XML in the response? Throwing an > Exception on the server just returns the text of the stacktrace in the > response. > > - Tim > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~----------~----~----~----~------~----~------~--~---
