问个asp的response.end 的问题,麻烦?

来源:百度知道 编辑:UC知道 时间:2024/06/09 23:30:59
<%
dim a,b,c
if request.form.count=0 then
response.end
end if
a=request.form("aa")
b=request.form("bb")
response.write a
response.write "+"
response.write b
response.write "="
c=clng(a)+clng(b)
response.write c
%>

在表单提交的时候什么都没写为什么不会结束程序,我写了
if request.form.count=0 then
response.end
end if

还有一个问题,我在表单里什么都没写为什么提示clng(a)+clng(b)类型不匹配

表单的代码是
<form name=tt action=yu.asp method=post>
a:<input type=text name=aa size=10>
<p>b:<input type=text name=bb size=10>
<input type=submit name=ok value="确定">
</form>

request.form.count的意思是你表单提交过来有几个(文本框,单选框....),无论你填于不填都是这么几个,所以是不会执行那个语句的.

clng(a)A是没值的所以会报错.