Dim A As Long
Dim B As Long
Dim C As Long
Dim N As Long
Dim I As Long
Dim D As Long
Private Sub Command1_Click()
List1.Clear
A = Text1.Text
B = Text2.Text
N = Text3.Text
List1.AddItem "........................................."
List1.AddItem "N" & vbTab & "AP" & vbTab & "GP"
List1.AddItem "........................................."
List1.AddItem 1 & vbTab & A & vbTab & A
C = A + B
D = A * B
List1.AddItem 2 & vbTab & C & vbTab & D
For I = 3 To N
C = B + C
D = B * D
List1.AddItem I & vbTab & C & vbTab & D
Next I
List1.AddItem "........................................."
End Sub
No comments:
Post a Comment
Note: only a member of this blog may post a comment.