Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] output to excel from in ASP.net after calling WF via service
Go
New
Search
Notify
Tools
Reply
  
[CLOSED] output to excel from in ASP.net after calling WF via service
 Login/Join
 
Gold member
posted
Hi,

I have an ASP.NET application that is calling 3 webfocus reports via a webservice one after the other. They have the option to get the output in excel, so after the return of the service, I check for the mime = application/vnd.ms-excel.

My issue is because there are 3 reports, excel doesn't seem to be opening fast enough, and the reports render back faster than excel can open, so I am losing report output. Has anyone had this issue before? If so, how did you fix it?


Code is as follows. I even tried putting it to sleep at the end of this, before the next report was rendered to give excel a chance to catch up.


If (ret.mime = "application/vnd.ms-excel") Then
Response.ClearHeaders()
Response.Buffer = True
Response.Clear()
Response.ContentType = "application/vnd.ms-excel"
'Response.AddHeader("Content-Disposition", "inline;filename=output.xlsx")
Dim headerAttributes As String = "attachment;filename=" & report.name & ".xlsx"

Response.AddHeader("Content-Disposition", headerAttributes)

Response.BufferOutput = True

Response.Write(ret.output)

Response.End()
Response.Flush()

This message has been edited. Last edited by: Kerry,


Version: 8.0.0.6
Windows platform
All output formats will probably be used.
 
Posts: 80 | Registered: June 25, 2009Reply With QuoteReport This Post
Platinum Member
posted Hide Post
Kowens,
This is really much more of an ASP.net question than it is a WebFOCUS question.

They way you would handle this in ASP.net should be the same way you'd handle retrieving and displaying multiple Excel documents from any source via ASP.net.

Have you thought of posting on:
forums.asp.net

I personally would almost wonder if the issue is that the web browser thinks its the same document coming back three times.

Have you tried targeting three separate i-frames with the outputs of these three Excel documents to see if it changes anything? The download HTTP Header's you have, *should* cause the file to download anyway even though its opening in an i-frame.

If this works proof-of-concept, there might be something more creative along these lines you could use.


WF 71.x, 76.x, 7701, 8.0 Beta OS: Linux, Win2k3, Win2k, Win2k8, WinXP


 
Posts: 203 | Registered: November 19, 2007Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] output to excel from in ASP.net after calling WF via service

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.