Private Sub Command1_Click() If Val(Text1.Text) = result Then Picture1.Print sexp; Text1.Text; Space$(10); "√" nok = nok + 1 Else Picture1.Print sexp; Text1.Text; Space$(10); "╳" nerror = nerror End If Text1.Text = "" Form_Activate Text1.SetFocus Form_Load
Picture1.Print sexp;text1.Text;space$(10);"错"
是分号,用来紧接着打印,没有分号,就是分行打印了.
冒号好像是用来分割两条语句的吧?
好久没用VB了,可能忘掉了.
If Val(Text1.Text) = result Then
Picture1.Print sexp; Text1.Text; Space$(10); "√"
nok = nok + 1
Else
Picture1.Print sexp; Text1.Text; Space$(10); "╳"
nerror = nerror
End If
Text1.Text = ""
Form_Activate
Text1.SetFocus
Form_Load
End Sub