By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
457,931 Members | 1,429 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 457,931 IT Pros & Developers. It's quick & easy.

Changing the Content-Type "invalids" the page.

P: n/a
Hi all,

I have a web form which contains a frame, (a form
containing a menu on the left and a web form containing a
datagrid on the right). Also there is a button (right
side) which transforms the datagrid content in a CSV file
and forces the user to download the file. The following is
the code used to force a download:

'strCadena contains the datagrid info separated by commas,
as a CSV file
Response.ContentType = "application/octet-stream"
Response.AddHeader("content-
disposition", "attachment;filename=Reporte_InfoRed.csv")
Response.Write(strCadena)
Response.End()

After the user saves the file, the links on the menu on
the left side don't work and the buttons on the right side
promt an error on the client side. I think it's because of
the change of the Content-Type. When I click on a menu
link and then view the history of the browser, the "name"
for the last page visited is "No page to display".

Does anybody know if there is any other way to force a
download without changing the Content_Type?

Thanks in advance.

God Bless.
Jul 19 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Hello,

I am looking for somebody who could help you on it. Thanks very much.

Best regards,
Yanhong Huang
Microsoft Online Partner Support

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

--------------------
!Content-Class: urn:content-classes:message
!From: "mvargasp" <ma*********@viabcp.com>
!Sender: "mvargasp" <ma*********@viabcp.com>
!Subject: Changing the Content-Type "invalids" the page.
!Date: Thu, 17 Jul 2003 09:19:11 -0700
!Lines: 30
!Message-ID: <00****************************@phx.gbl>
!MIME-Version: 1.0
!Content-Type: text/plain;
! charset="iso-8859-1"
!Content-Transfer-Encoding: 7bit
!X-Newsreader: Microsoft CDO for Windows 2000
!Thread-Index: AcNMfyg2/8gh8xWQSeSXwRLwOo8PKQ==
!X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
!Newsgroups: microsoft.public.dotnet.general
!Path: cpmsftngxa06.phx.gbl
!Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.general:101543
!NNTP-Posting-Host: TK2MSFTNGXA12 10.40.1.164
!X-Tomcat-NG: microsoft.public.dotnet.general
!
!Hi all,
!
!I have a web form which contains a frame, (a form
!containing a menu on the left and a web form containing a
!datagrid on the right). Also there is a button (right
!side) which transforms the datagrid content in a CSV file
!and forces the user to download the file. The following is
!the code used to force a download:
!
!'strCadena contains the datagrid info separated by commas,
!as a CSV file
!Response.ContentType = "application/octet-stream"
!Response.AddHeader("content-
!disposition", "attachment;filename=Reporte_InfoRed.csv")
!Response.Write(strCadena)
!Response.End()
!
!After the user saves the file, the links on the menu on
!the left side don't work and the buttons on the right side
!promt an error on the client side. I think it's because of
!the change of the Content-Type. When I click on a menu
!link and then view the history of the browser, the "name"
!for the last page visited is "No page to display".
!
!Does anybody know if there is any other way to force a
!download without changing the Content_Type?
!
!Thanks in advance.
!
!God Bless.
!
Jul 19 '05 #2

P: n/a
Hello,

I am looking for somebody who could help you on it. Thanks very much.

Best regards,
Yanhong Huang
Microsoft Online Partner Support

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

--------------------
!Content-Class: urn:content-classes:message
!From: "mvargasp" <ma*********@viabcp.com>
!Sender: "mvargasp" <ma*********@viabcp.com>
!Subject: Changing the Content-Type "invalids" the page.
!Date: Thu, 17 Jul 2003 09:19:11 -0700
!Lines: 30
!Message-ID: <00****************************@phx.gbl>
!MIME-Version: 1.0
!Content-Type: text/plain;
! charset="iso-8859-1"
!Content-Transfer-Encoding: 7bit
!X-Newsreader: Microsoft CDO for Windows 2000
!Thread-Index: AcNMfyg2/8gh8xWQSeSXwRLwOo8PKQ==
!X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
!Newsgroups: microsoft.public.dotnet.general
!Path: cpmsftngxa06.phx.gbl
!Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.general:101543
!NNTP-Posting-Host: TK2MSFTNGXA12 10.40.1.164
!X-Tomcat-NG: microsoft.public.dotnet.general
!
!Hi all,
!
!I have a web form which contains a frame, (a form
!containing a menu on the left and a web form containing a
!datagrid on the right). Also there is a button (right
!side) which transforms the datagrid content in a CSV file
!and forces the user to download the file. The following is
!the code used to force a download:
!
!'strCadena contains the datagrid info separated by commas,
!as a CSV file
!Response.ContentType = "application/octet-stream"
!Response.AddHeader("content-
!disposition", "attachment;filename=Reporte_InfoRed.csv")
!Response.Write(strCadena)
!Response.End()
!
!After the user saves the file, the links on the menu on
!the left side don't work and the buttons on the right side
!promt an error on the client side. I think it's because of
!the change of the Content-Type. When I click on a menu
!link and then view the history of the browser, the "name"
!for the last page visited is "No page to display".
!
!Does anybody know if there is any other way to force a
!download without changing the Content_Type?
!
!Thanks in advance.
!
!God Bless.
!
Nov 22 '05 #3

P: n/a
Hello,

I am looking for somebody who could help you on it. Thanks very much.

Best regards,
Yanhong Huang
Microsoft Online Partner Support

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

--------------------
!Content-Class: urn:content-classes:message
!From: "mvargasp" <ma*********@viabcp.com>
!Sender: "mvargasp" <ma*********@viabcp.com>
!Subject: Changing the Content-Type "invalids" the page.
!Date: Thu, 17 Jul 2003 09:19:11 -0700
!Lines: 30
!Message-ID: <00****************************@phx.gbl>
!MIME-Version: 1.0
!Content-Type: text/plain;
! charset="iso-8859-1"
!Content-Transfer-Encoding: 7bit
!X-Newsreader: Microsoft CDO for Windows 2000
!Thread-Index: AcNMfyg2/8gh8xWQSeSXwRLwOo8PKQ==
!X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
!Newsgroups: microsoft.public.dotnet.general
!Path: cpmsftngxa06.phx.gbl
!Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.general:101543
!NNTP-Posting-Host: TK2MSFTNGXA12 10.40.1.164
!X-Tomcat-NG: microsoft.public.dotnet.general
!
!Hi all,
!
!I have a web form which contains a frame, (a form
!containing a menu on the left and a web form containing a
!datagrid on the right). Also there is a button (right
!side) which transforms the datagrid content in a CSV file
!and forces the user to download the file. The following is
!the code used to force a download:
!
!'strCadena contains the datagrid info separated by commas,
!as a CSV file
!Response.ContentType = "application/octet-stream"
!Response.AddHeader("content-
!disposition", "attachment;filename=Reporte_InfoRed.csv")
!Response.Write(strCadena)
!Response.End()
!
!After the user saves the file, the links on the menu on
!the left side don't work and the buttons on the right side
!promt an error on the client side. I think it's because of
!the change of the Content-Type. When I click on a menu
!link and then view the history of the browser, the "name"
!for the last page visited is "No page to display".
!
!Does anybody know if there is any other way to force a
!download without changing the Content_Type?
!
!Thanks in advance.
!
!God Bless.
!
Nov 22 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.