|
1. It is recommended not to use ":"
2. The reward symbol is written in reverse, it should be
s1 = Text1.Text
s2 = Text2.Text
3. It seems you haven't understood the use of value-granting symbols
Text3.Text = s3 = s2 + s1
Is wrong, s3 is not needed at all
Correct writing
Text3.Text = s2 + s1
4.Text3.Text is a string type, and s1, s2 are integer types, so conversion is required.
amend as below
Private Sub Command1_Click ()
Dim s1%, s2%
s1 = cint (Text1.Text)
s2 = cint (Text2.Text)
Text3.Text = cstr (s2 + s1)
End Sub |
|