VB Program to find factorial


Program to find factorial of a number

Sample :



I can't show you complete code Directly so download full code from below .
Download the output  for the form (design).





Private Sub Text1_Change()
    Dim num, ans As Double
    num = Val(Text1.Text)
    ans = num
    While num > 1
        ans = ans * (num - 1)
        num = num - 1
    Wend
    Text2.Text = ans
End Sub

Full Code :
Output(factorial.exe)

Full code(factorial.doc)

Full project(factorial.zip)

*Note Full project require Visual Basic 6.0