大家帮我看一段代码,哪里怎么改正错误?
<%
PhotoPath="photo/"
MaxPhotoSize="102400"
if request("action")="upload" then
call uploadphoto()
else
call upform()
end if
sub uploadphoto()
dim upload,file
Dim fso
%>
<!--#INCLUDE FILE="inc/upload.inc" -->
<%
set upload=new upload_5xSoft
if upload.form("info")="" then
Errmsg=Errmsg+"<br>"+"<li>请输入图片名称."
founderr=true
else
info=trim(upload.form("info"))
end if
newtype=upload.form("newtype")
set file=upload.file("upfile")
fileExt=lcase(right(file.filename,4))
if file.filesize<100 then
Errmsg=Errmsg+"<br>"+"<li>请先选择你要上传的文件."
founderr=true
elseif fileEXT<>".gif" and fileEXT<>".jpg" then
Errmsg=Errmsg+"<br>"+"<li>所要上传文件的格式错误!."
founderr=true
elseif file.filesize>MaxPhotoSize then
Errmsg=Errmsg+"<br>"+"<li>文件大小超过了"&MaxPhotoSize/1024&"K限制."
founderr=true
end if
if founderr=true then
$$$$$$$$$$$call error(Errmsg)
exit sub
end if
set fso = CreateObject("Scripting.FileSystemObject")
path=server.mappath(PhotoPath)
if fso.folderexists(path)=false then
fso.createfolder(path)
end if
set fso=nothing
if right(PhotoPath,1)<>"/" then
PhotoPath=PhotoPath&"/"
end if
datetime=year(date)&month(date)&day(date)&hour(now)&minute(now)&second(now)
filename=file.filename
file.SaveAs Server.mappath(PhotoPath&filename)
错误提示是:
Microsoft VBScript 运行时错误 错误 '800a000d'
类型不匹配: 'error'
/长佳特/admin/picsend.asp,行 124
错误位置我用$$$$$$$$$$$做了记号