易截截图软件、单文件、免安装、纯绿色、仅160KB

asp生成excel报表问题

在test_manager.asp中有一个按钮,点击之后到test_result.asp,程序如下
VBScript code:
<%@ Language=VBScript %>
<!-- #include File="../Conn.Asp" -->
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="css.css" rel="stylesheet" type="text/css">

<body>
<%
id=request("action")
response.Write(id)
FilePath=Server.MapPath("test_result.xls")
Set Fso=server.createobject("scripting.filesystemobject")
If Fso.FileExists(FilePath) then
Fso.DeleteFile FilePath,true
End If

Dim xlWorkSheet
Dim xlApplication
Set xlApplication = Server.CreateObject("Excel.Application")
xlApplication.Visible = False
xlApplication.Workbooks.Add

Set xlWorksheet = xlApplication.Worksheets(1)
xlWorksheet.Cells(1,1).Value = "员工编号"
xlWorksheet.Cells(1,2).Value = "中文名"
iRow = 2
sql="select * from survey_userlist where status=1 and surveyid="&id&" order by emailaddress"
set rs=server.CreateObject("adodb.recordset")
rs.open sql,conn,3,1
if not rs.eof then
do while not rs.eof
xlWorksheet.Cells(iRow,1).Value=rs("emailaddress")
xlWorksheet.Cells(iRow,2).Value=rs("c_name")


相关问答:

急求ASP。NETC#购物车代码

最近在做个网上商城,购物车模块,没有做过,麻烦各位帮忙说下大致说下思路,能发一份源码更好。小弟先谢过各位了;
QQ:413763818;
eamil:swebook@126.com
网上一大堆!

www.51aspx.com

去下 ......

ASP.NET表格弄得痛苦死了 - .NET技术 / ASP.NET

调整了这里,那里出问题。
有没有什么好的方法,像调整对话框一样????
找个专门做页面的

在dreamweaver里调。。。也可以直接控制HTML代码

确实痛苦 感同身受呀

哈哈 坚决路过。

用DW吧,VS搞设计 ......

关于asp六大对象外的知识 - Web 开发 / ASP

一般的asp 书籍 只介绍 asp的六大对象 但像 
Set fso = CreateObject("Scripting.FileSystemObject")
这些技术 却没有见过 
这些东西是asp的哪方面知识 
好像有 activeXobject什么 ......

asp.net批量上传图片 - .NET技术 / ASP.NET

asp.net批量上传图片最好有源码,在线等!!!!!!!
源码很长的。

参考

C# code:
HttpFileCollection files = HttpContext.Current.Request.Files;
if (files.Count <= 1)
{
......

哪个有asp.net域名查询程序 - .NET技术 / ASP.NET

发给我一份 280535258@qq.com 谢谢 要分可以说 多少都行

参考::!!!!
前台
<%@ Page language="c#" Codebehind="Domain.aspx.cs" AutoEventWireup="false" Inherits=&q ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号