利用ASP生成EXECL文档
2001-07-23 11:02:20 来源:WEB开发网核心提示:<%set conn=server.createobject("adodb.connection")conn.open application("connstring")set rs=server.createobject("Adodb.recordset&quo
<%
set conn=server.createobject("adodb.connection")
conn.open application("connstring")
set rs=server.createobject("Adodb.recordset")
sql="select * from xxloginteachers order by jsid desc"
rs.open sql,conn
do while not rs.eof
msg=msg & rs("jsid") & chr(9) & rs("jsxm") & vbcrlf
rs.movenext
loop
set f=server.createobject("scripting.filesystemobject")
set myfile=f.createtextfile("d:\xmllover.xls",true)
myfile.close
%>
已生成xmllover.xls!!!!
set conn=server.createobject("adodb.connection")
conn.open application("connstring")
set rs=server.createobject("Adodb.recordset")
sql="select * from xxloginteachers order by jsid desc"
rs.open sql,conn
do while not rs.eof
msg=msg & rs("jsid") & chr(9) & rs("jsxm") & vbcrlf
rs.movenext
loop
set f=server.createobject("scripting.filesystemobject")
set myfile=f.createtextfile("d:\xmllover.xls",true)
myfile.close
%>
已生成xmllover.xls!!!!
更多精彩
赞助商链接