TEXTBOX的字符替换功能
If (txtValueList.Visible) Then
txtValueList.Text = Trim$(txtValueList.Text)
If (txtValueList.Text <> "") Then
strValueList = ""
aryValueList = Split(txtValueList.Text, vbCrLf)
For i = LBound(aryValueList) To UBound(aryValueList)
If (CStr(aryValueList(i)) <> "") Then
If (Len(CStr(aryValueList(i))) > CInt(txtMaxLength.Text)) Then
MsgBox Replace$(GetResString(langFrmFieldErrExceedLen), "%VALUE%", CStr(aryValueList(i))), vbExclamation, Me.Caption
txtValueList.SetFocus
Exit Sub
End If
strValueList = strValueList & CStr(aryValueList(i)) & ","
End If
Next
End If
End If
如何在这段代码中添加上一段新的代码,就是对输入的字符进行一个判断,如果含有,和;的,就取代为空格,txtValueList为textbox的名字