Subscript out of range

vividfox 2004-01-15 08:36:08
LyfUpload 错误 '80020009'

Subscript out of range

/金和田/manager/doupload.asp,行 15


代码如下:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>文件上传</title>
</head>

<body>
<!--#include file="conn.asp"-->
<!--#include file="top.asp"-->
<%if session("user")=empty then
response.Write "<div align='center'>您没有登陆!请返回<a href='login.asp'>登陆页</a>登陆!</div>"
else

set uploadphoto = Server.CreateObject("LyfUpload.UploadFile")

for i=1 to cint(request.QueryString("counts"))
if obj.request("button"&i)=empty then
response.Write ("<div align='center'>文件"&i&"没有选择!请返回<input type=button value='上一页' onClick='history.back(-1)' >选择完整!</div>")
response.end
end if
next

uploadphoto.extname="gif,jpg,jpeg"

for i=1 to request.QueryString("counts")
filename=uploadphoto.savefile("button"&i,server.MapPath("/")+"/photo/",false)
filenames=filenames+";"+filename
if filename="1" then
response.Write("<div align='center'>文件"&i&"上传图片必须是jpg,jpeg,gif格式!</div>")
response.End
elseif filename="3" then
response.Write("<div align='center'>文件"&i&"图片名已存在,请重新命名!<div>")
response.End
end if
next

if request.QueryString("id")=empty then
objrs.open "select 图片 from "&request.QueryString("typename")&"",conn,1,3
objrs.addnew
else objrs.open "select 图片 from"&request.QueryString("typename")&" where 序号="&request.QueryString("id")&"",conn,1,3
end if

objrs("图片")=filenames
objrs.update

response.Write("<div align='center'>所有文件上传成功!请返回<a href='manager.asp?typename="&request.QueryString("typename")&"'>网站后台管理页面!</a></div>")

end if%>
<!--#include file="buttom.asp"-->

</body>
</html>

第15行是 set uploadphoto = Server.CreateObject("LyfUpload.UploadFile")

请各位帮忙解决,小弟很急!!!
...全文
237 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
vividfox 2004-01-16
  • 打赏
  • 举报
回复
那个组件我已经注册了阿!!
luluso 2004-01-15
  • 打赏
  • 举报
回复
在开始菜单的运行里输入:
regsvr32 d:lyfupload.dll
luluso 2004-01-15
  • 打赏
  • 举报
回复
使用前先注册下lyfupload的组件
开始-运行-那里注册下lyf的那个dll文件.
aoeiuvcom 2004-01-15
  • 打赏
  • 举报
回复
看看LyfUpload这个组件的帮助

应该是使用上的错误或者笔误

28,390

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧