text2改变的时候text1 也改变
当在text2中按回车的时候就添加到text1后面
Public ss As String
Public ss1 As String
Private Sub Form_Load()
ss1 = Text1.Text
End Sub
Private Sub Text2_Change()
ss = Text2.Text
Text1.Text = ss1 + ss
End Sub
Private Sub Text2_KeyUp(KeyCode As Integer, Shift As Integer)
If KeyCode = 13 Then
ss1 = ss1 + ss
ss = ""
text2.text=ss
Text1.Text = ss1 + ss
End If
End Sub
楼下的:text2变的时候难道就只有最后一个字符变,不会中间的变?你没考虑删除一个字符等情况,只考虑了顺序输入的情况,这是最简单的!