ES-Components
asked on
Is There A Way To Have An ASP Web Page With A Table Exported To Excel?
I have an ASP Web Page that displays a dynamic table with data. I am using Internet Explorer 11. If I right click and try "Export To Excel" I get an error.
"Unable to open http://.........asp. Cannot download the information.
Is there a way to get this to work?
I can right click and select and copy the table on the ASP web page and paste it into excel manually. I would prefer not to do this.
Thank you for any help.
Rick
"Unable to open http://.........asp. Cannot download the information.
Is there a way to get this to work?
I can right click and select and copy the table on the ASP web page and paste it into excel manually. I would prefer not to do this.
Thank you for any help.
Rick
ASKER
This is the first few lines of code to this web page. You can see where I put your suggestion.
I get an HTTP500 error. The website can not display the page. Possible programming error.
Any ideas?
Thank you...
Rick
<%@LANGUAGE="VBSCRIPT"%>
<!--#include file="Connections/Customer History2.a sp" -->
<!--#include file="Connections/OpenOrde rsCustomer .asp" -->
<%
Response.ContentType = "application/vnd.ms-excel"
Response.AppendHeader "content-disposition", " filename=TheFileName.xls"
%>
<%
Dim Recordset1__ShipTo
Recordset1__ShipTo = "1"
If (Request.Form("ShipTo") <> "") Then
Recordset1__ShipTo = Request.Form("ShipTo")
End If
%>
<%
Dim Recordset1__varStartRange
Recordset1__varStartRange = "1/1/07"
If (Request.Form("Date1") <> "") Then
Recordset1__varStartRange = Request.Form("Date1")
End If
%>
I get an HTTP500 error. The website can not display the page. Possible programming error.
Any ideas?
Thank you...
Rick
<%@LANGUAGE="VBSCRIPT"%>
<!--#include file="Connections/Customer
<!--#include file="Connections/OpenOrde
<%
Response.ContentType = "application/vnd.ms-excel"
Response.AppendHeader "content-disposition", " filename=TheFileName.xls"
%>
<%
Dim Recordset1__ShipTo
Recordset1__ShipTo = "1"
If (Request.Form("ShipTo") <> "") Then
Recordset1__ShipTo = Request.Form("ShipTo")
End If
%>
<%
Dim Recordset1__varStartRange
Recordset1__varStartRange = "1/1/07"
If (Request.Form("Date1") <> "") Then
Recordset1__varStartRange = Request.Form("Date1")
End If
%>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Open in new window