航空器机型序列号:下面代码有什么问题,请大家帮忙~~

来源:百度文库 编辑:查人人中国名人网 时间:2024/05/14 05:06:54
<%
function Create_SoftView(SoftID,HtmlTemplate)
dim isSpecial
isSpecial=1
'set rs=server.createobject("adodb.recordset")
sql="select * from SoftDown_SoftInfo where SoftID="&SoftID
rs.open sql,conn,1,1
Points=rs("Points")
keys=checkStr(rs("SoftName"))
CatalogID=rs("CatalogID")
strSoftName=rs("SoftName")&" "&rs("SoftVer")
strLanguage=rs("Language")
if not isnull(rs("SoftViewImg")) and rs("SoftViewImg")<>"" then
strSoftViewImg=" <a href=""../SoftImg.asp?SoftID="&SoftID&""" target=""_blank""><img src=""../images/screen.gif"" border=""0"" align=""absmiddle"" title=""查看预览图""> "
else
strSoftViewImg=""
end if
strSoftType=rs("CatalogName")
strSystem=rs("System")
strLicenceType=rs("LicenceType")
if rs("SoftSize")>1024 then
strSoftSize=round(rs("SoftSize")/1024,2)&" MB"
else
strSoftSize=rs("SoftSize")&" KB"
end if
strRank="<img src=""../images/"&rs("Rank")&"star.gif"">"
strSoftTime=rs("SoftTime")
if (not isnull(rs("SoftFrom"))) or rs("SoftFrom")<>"" then
strSoftFrom="<a href="""&rs("SoftFrom")&""" target=""_blank"">"&cutStr(rs("SoftFrom"),35)&"</a>"
else
strSoftFrom=""
end if
strHits="本日:"&rs("DayHits")&" 本 周:"&rs("WeekHits")&" 本月:"&rs("MonthHits")&" 总计:"& rs("AllHits")
strContent=UBBCode(rs("Content"))
if (not isnull(rs("images"))) or rs("images")<>"" then
strImages="<img src='"&rs("Images")&"' border=0 width=180 height=230>"
else
strImages=""
end if
if isNull(rs("Email")) or rs("Email")="" then
strEmail="无"
else
strEmail="<a href=""mailto:"&rs("Email")&""">"&rs("Email")&"</a>"
end if
if isNull(rs("RegURL")) or rs("RegURL")="" then
strRegURL="无"
else
strRegURL=rs("RegURL")
end if

if rs("EssayNum")=0 then
strEssay="目前没有用户参与评价 "

代码太长放不下,请到www.dy52.org/1.txt下载
我运行提示
ADODB.Field 错误 '800a0bcd'

BOF 或 EOF 中有一个是“真”,或者当前的记录已被删除,所需的操作要求一个当前的记录。

/admin/Create_Soft_View_inc.asp,行 82

把这句Special=rs("Special")
放在if not(rs.eof and rs.bof) then后就行了
有可能查询结果为空,所以要先判断查询结果不为空才能读取字段

脑袋有问题

这哪能看出来啊,又不是自己做的,有点像显示桌面的代码