Results 1 to 3 of 3

Thread: ExcelView as successView keeps the SimpleFormControllers url

Hybrid View

  1. #1

    Default ExcelView as successView keeps the SimpleFormControllers url

    I'm using SimpleFormController to upload a file and return an ExcelView as the successView. The upload is working and the view is rendering an
    excel file, but the name is the same as formView:
    Code:
    <property name="formView"><value>load</value></property>
    <property name="successView"><value>results_excelView</value></property>		<property name="sessionForm"><value>true</value></property>
    the resulting url is: load.htm.xls upon success, which appears as load.htm
    in the address. When I attempt to save this file from the browser,
    I get very strange behaviour, and excel typically crashes.
    ???

    [/code]

  2. #2
    Join Date
    Aug 2004
    Location
    Southampton, UK
    Posts
    826

    Default

    Try setting a response header like this:

    Content-Disposition: inline; filename=myFile.xls

    Rob
    Rob Harrop
    Lead Engineer, dm Server
    SpringSource
    http://www.springsource.com

    Co-Author - Pro Spring

  3. #3

    Default

    Thanks Rob! That did the trick. I actually went with attachment Content-Disposition for this case. The crashes were due to the fact that I am using a template whose author loves the use of...3d formatting and other
    interesting (and unsupported in POI) features of excel.

    Is it possible to update the reference 13.6. Document views (PDF/Excel)
    with this tip, and possible a warning about accepting spreadsheet templates
    from the business group?

Similar Threads

  1. why I never reach successView?
    By vincent in forum Web
    Replies: 3
    Last Post: Oct 10th, 2005, 10:30 AM
  2. Replies: 2
    Last Post: Apr 29th, 2005, 11:16 AM
  3. Replies: 3
    Last Post: Apr 28th, 2005, 02:27 AM
  4. Replies: 1
    Last Post: Apr 13th, 2005, 09:49 PM
  5. successView value
    By roofimon in forum Web
    Replies: 9
    Last Post: Jan 25th, 2005, 08:23 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •