473,806 Members | 2,253 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Streaming XLS to the client - ignore previous thread

CJM
[Sorry - having a bad day! Ignore the previous thread]

I have a page which allows the user to open one of several spreadsheets by
streaming the XLS to the client.

On my development site, everything appears to work fine. On the live site,
it works fine for the vast majority of users, but not for my colleague & I.

When this page is called with the correct inputs, the standard
Open/Save/Cancel/More Info dialog should appear. In the dialog, it gives the
following details:

Filename: Gothenburg Sweden.xls
File type: Microsoft Excel Spreadsheet
From: Servername

Clicking on open, means that the file will be opened in the local copy of
Excel; this works for most people, except one colleague and myself. In our
case, after clicking on Open, we get the following error msg:

"Internet Explorer cannot open travel.asp?jour ney=1 from <servername>
Internet Explorer was not able to open this internet site. The requested
site is either unavailable or cannot be found. Please try again later."

Anybody got any ideas about this?

TIA

Chris

Code Snippet:

sFileDir = Application("XL SDir")

If Len(sJourney) then
Select Case sJourney
Case 1
sFileName = "Gothenburg Sweden.xls"
sFilePath = sFileDir & sFilename
Response.AddHea der "content-disposition","a ttachment; filename=" &
"Gothenburg Sweden.xls"
Case 2
sFileName = "Nyköping Sweden.xls"
sFilePath = sFileDir & sFilename
Response.AddHea der "content-disposition","a ttachment; filename=" &
"Nyköping Sweden.xls"
Case Else
Response.Redire ct "travel.asp "
End Select

' Create your header information
Response.Conten tType = "applicatio n/asp-unknown"

' Create and configure your object
Set oFStream = Server.CreateOb ject("ADODB.Str eam")
oFStream.Open()
oFStream.Type = 1
oFStream.LoadFr omFile(sFilePat h)

' Stream it to the client
Response.Binary Write oFStream.Read()

' Cleanup
oFStream.Close
Set oFStream = Nothing

' force the end
Response.End
End If

Jul 19 '05 #1
6 3624
Hi Chris,

From your description, the problem only occur on two clients. If other user
browser to same web page, they will get correct result. Is this right?

Regarding the problem, can you open other ASP pages in the same
application. For example, some page return normal HTML code instead XLS?

I also notice you used "applicatio n/asp-unknown", you may change it to
"applicatio n/x-msexcel" to see if this will help. Here is a complete sample
to send XSL from ASP:

HOWTO: Use the ADODB.Stream Object to Send Binary Files to the Browser
through ASP
http://support.microsoft.com/default...;EN-US;Q276488

Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Jul 19 '05 #2
CJM

"[MSFT]" <lu******@onlin e.microsoft.com > wrote in message
news:hr******** ******@cpmsftng xa10.phx.gbl...
Hi Chris,

From your description, the problem only occur on two clients. If other user browser to same web page, they will get correct result. Is this right?

As far as I know, only the two clients have this problem. In both cases, if
they try and access the development version of the application (which is on
my machine) they both work, but for the live version (on a Win2k3 server)
they dont.
Regarding the problem, can you open other ASP pages in the same
application. For example, some page return normal HTML code instead XLS?

The application has several other ASP pages which all work normally.
I also notice you used "applicatio n/asp-unknown", you may change it to
"applicatio n/x-msexcel" to see if this will help. Here is a complete sample to send XSL from ASP:

I've changed this but it doesnt appear to have made a difference.
HOWTO: Use the ADODB.Stream Object to Send Binary Files to the Browser
through ASP
http://support.microsoft.com/default...;EN-US;Q276488


I'll check this out..

Thanks
Jul 19 '05 #3
Hi Chris,

You may try to clear the two clients computer's internet temporary files to
see if this will help. Additionally, It is better to use local
administrator to test so that we can ensure IE have enough permission to
load the XSL file.

Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Jul 19 '05 #4
CJM
Luke,

I've tried clearing the temporary files but this has made no difference.
This is a sustained problem, so I didnt think this would be the issue, but
at least it is crossed off the list.

As for permissions, both users are Domain Administrators so we have
sufficient rights.

Chris

"[MSFT]" <lu******@onlin e.microsoft.com > wrote in message
news:lL******** ******@cpmsftng xa10.phx.gbl...
Hi Chris,

You may try to clear the two clients computer's internet temporary files to see if this will help. Additionally, It is better to use local
administrator to test so that we can ensure IE have enough permission to
load the XSL file.

Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Jul 19 '05 #5
Hi Chris,

You may take a look at following articles to see if they can address the
problem:

Internet Explorer Cannot Download Office Documents from an IIS Server When
Content Expiration Is Set to Expire Immediately
http://support.microsoft.com/default...;EN-US;Q317208

An Error Message Occurs If You Click "Save Target As" for a Link
http://support.microsoft.com/default...;EN-US;Q319032

Cannot open an Excel 2003 workbook by using Internet Explorer 6.0
http://support.microsoft.com/default...;EN-US;Q840386

PRB: Internet Explorer Is Unable to Open Office Documents from an SSL Web
Site
http://support.microsoft.com/default...;EN-US;Q316431
Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Jul 19 '05 #6
CJM
I've contacted MS Support and they have sent me the patch mentioned in
Q840386, and it has worked a treat.

Thanks

Chris

"[MSFT]" <lu******@onlin e.microsoft.com > wrote in message
news:R5******** ******@cpmsftng xa10.phx.gbl...
Hi Chris,

You may take a look at following articles to see if they can address the
problem:

Cannot open an Excel 2003 workbook by using Internet Explorer 6.0
http://support.microsoft.com/default...;EN-US;Q840386
Luke
Microsoft Online Support

Jul 19 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
1652
by: CJM | last post by:
I have a page which allows the user to open one of several spreadsheets by streaming the XLS to the client.
22
5716
by: googlegroups | last post by:
I am playing with the XMLHTTPRequest method to perform client/server transactions. I have it set up right now so that when readyState is 4, it takes the XML and processes it. This works great until there is alot of data. In that case, the user will have to wait for the data to come back which may take a minute or so. I don't want the user to have to wait. Is it possible for javascript to periodically (while still receiving more data)...
15
4500
by: Michael Rybak | last post by:
hi, everyone. I'm writing a 2-players game that should support network mode. I'm now testing it on 1 PC since I don't have 2. I directly use sockets, and both client and server do computations, the only data transfered is user mouse/kbd input. It works synchronously, but somehow, when I play in client window, both client and server have 17 fps, while when playing in server window, server has 44 fps while client ...
1
2161
by: JC | last post by:
Hi, I have to play a streaming audio. So in a thread I play audio as follow thread{ //some code for(;;){ //some code waveOutPrepareHeader(hwo, &(whdr), sizeof(WAVEHDR)); waveOutWrite(hwo, &(whdr), sizeof(WAVEHDR));
5
1569
by: John | last post by:
Hi all, I have an (well, what I think to be, at least) interesting question: Is it possible to stream data down to the client and, after a certain amount of data has been streamed, allow the client to begin interacting with that data whilst still streaming data down? Also, if it is possible, how would one go about coding this? Would some sort of predfined bit of streaming be finished and notify the client (i.e. some form of Javascript...
3
2345
by: A.M-SG | last post by:
Hi, I have a ASP.NET aspx file that needs to pass large images from a network storage to client browser. The requirement is that users cannot have access to the network share. The aspx file must be the only method that users receive image files.
6
2734
by: | last post by:
Hi all, is there a better way to stream binary data stored in a table in sql 2005 to a browser in .net 2.0? Or is the code same as in .net 1.1? We noticed that in certain heavy load scenarios, every now and then the client would timeout and have to re-initiate the request... TIA!
5
3557
by: pmakoi | last post by:
dear all this might be a piece of cake for some of you out there but it is causing me a lot of stress given the fact that there is not enogh documentation out there regarding this topic I am writing a web service that uses soap with attachments to send a large streaming data, The concept works quite well but when I started to test it I got this problem. When my client program calls a method that should return a real time data the...
1
2865
by: Faisal Shafiq | last post by:
I want to upload a file direct to the Silverlight Streaming Service from a Web Client such as silverlight application. As per our product requirement we want to upload a .WMV file directly from silverlight client to Silverlight streaming service. I tried to user WebClient and HttpWebRequest for that purpose but, unfortunately I can found the way to do so. There are some problems with both classes. 1. There is no property of get...
0
9718
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9596
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10617
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10364
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10370
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9186
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5545
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4328
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
3008
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.