sub sub_name(参数)
子函数体
end sub
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<[email=%@LANGUAGE=]%@LANGUAGE="VBSCRIPT[/email]" CODEPAGE="65001" %>
<%
sub CountN(n)
dim c
for i = 1 to n
c = c + i
next
response.Write("result: " & c & "<br />")
end sub
call CountN(5)
countN 6
%>
</body>
</html>
result: 15
result: 21
欢迎光临 曲径通幽论坛 (http://www.groad.net/bbs/) | Powered by Discuz! X3.2 |