Please start any new threads on our new site at http://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Development Tools
 ASP.NET
 Getting a file not found error on IIS?
 Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

o2bnlv
Starting Member

5 Posts

Posted - 07/11/2012 :  00:27:17  Show Profile  Reply with Quote
Running on Vista. All other files are appearing normally. Here's the code, which I'm using to create a table which will then be exported to Excel:


<%
Response.ContentType = "application/vnd.ms-excel"
Response.AddHeader "Content-Disposition", "filename=excelfile.xls"
set conn = server.CreateObject ("ADODB.Connection")
  conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & server.MapPath ("users.mdb")
   set rs = server.CreateObject ("ADODB.Recordset")
rs.open "SELECT * FROM Sales WHERE adminid =" & session("username") & "", conn, 3,3
%>
</head>
<body>
<table>
<%
do while not rs.EOF
%>
<tr>
<td><%=rs.Fields("saletime")%></td>
<td><%=rs.Fields("level2id")%></td>
<td><%=rs.Fields("itemdesc")%></td>
<td><%=rs.Fields("itemprice")%></td>
</tr>
<%
rs.Movenext
loop
rs.Close
set rs=nothing
set conn = nothing
%>
</table>

  Previous Topic Topic Next Topic  
 Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.02 seconds. Powered By: Snitz Forums 2000