编程 为什么不执行?

来源:百度知道 编辑:UC知道 时间:2024/06/23 16:49:14
<html>
<head>
<title>无标题文档</title>
</head>

<body>
<script language="vbscript">
Sub ChklastWhile()
dim a.b
a=0
b=20
do While b>10
b = b - 1
a = a + 1
Loop
MsgBox "chongfule" & a & "ci"
</script>
</body>
</html>
为什么不执行?哪里错了
End Sub 加了也不行

你不调用sub,怎么会能执行

<html>
<head>
<title>无标题文档</title>
</head>

<body>
<script language="vbscript">
Sub ChklastWhile()
dim a,b
a=0
b=20
do While b>10
b = b - 1
a = a + 1
Loop
MsgBox "chongfule" & a & "ci"
End Sub

ChklastWhile
</script>
</body>
</html>