I am a lecturer in ICT and have been roped into teaching
VB - only I don't know
VB. I can design etc. Anyway I am trying to code a program - the problem statement is this:
Design a program to read ten numbers from a keyboard and display their sum (addition) on the monitor screen.
This is the code I have developed so far - this is the first time ive ever touche a programming language - i know this code is very simple but please dont laugh at me lol.
Private Sub Command1_Click()
Dim total As Double
Static count As Double
Number = Text1.Text
total = 0
count = 1
If count <= 10 Then
total = total + Number
count = count + 1
ElseIf count > 10 Then
Form1.Print "The sum of the 10 numbers is: "; total
End If
End Sub
Can any body please tell me where I'm going wrong as I truly do not have a clue.
T