[讨论]帮我改改调用Sub 过程
1. 编写计算1!+2!+3!+……n!的Sub过程,在窗体的Click事件中调用该过程,输出计算结果。
我写的代码:
Sub factS(ByVal n As Integer, fac)
fac = 1
For i = 1 To n
fac = fac * i
nexti
End Sub
Private Sub Form_Click()
Dim a As Integer, b As Integer
a = Val(InputBox("输入项数"))
Call factS(a, fac)
??????????
Print fac;
End Sub
[此贴子已经被作者于2007-6-4 16:11:52编辑过]