主题:  纯ASP代码上传至数据库,不解之处

sundy122

职务:普通成员
等级:1
金币:0.0
发贴:5
#12004/11/7 0:22:32
我看了教程 favorites.myrice.com/eschool/asp/upimage.htm
upload.htm 和 process.asp 都没有问题,唯在 showimg.asp 的
rec.open strsql,connGraph,1,1 出了错.

showimg.asp
<%
set connGraph=server.CreateObject("ADODB.connection"
connGraph.ConnectionString="driver={Microsoft Access Driver (*.mdb)};DBQ=" & server.MapPath("images.mdb" & ";uid=;PWD=;"
connGraph.Open
set rec=server.createobject("ADODB.recordset"
strsql="select img from images where id=" & trim(request("id")
rec.open strsql,connGraph,1,1
Response.ContentType = "image/*"
Response.BinaryWrite rec("img".getChunk(7500000)
rec.close
set rec=nothing
set connGraph=nothing
%>
请知道的人回复一下,谢谢了