1、这样没问题:
'''
Dim str As String = "在控件中每输入,或删除一个字符。都会触发TextChanged事件,"
str = str.TrimEnd("。").TrimEnd(",").TrimEnd(";").Replace(":","").Replace(";",",").Replace(",",",").Replace("、",",").Replace("。",",") & "。"
Output.Show(str)
2、文本框textchang代码,在文本框中编辑时为什么出现一些句号单独成了一段,也删不掉:
Dim txt As WinForm.TextBox = e.Form.Controls("TextBox01")
If txt.text.EndsWith(chr(10)) = False Then
Dim ary() As String = txt.Text.Split(chr(13))
Dim str As String = ""
For Each s As String In ary
s =s.TrimEnd("。").TrimEnd(",").TrimEnd(";").Replace(":","").Replace(";",",").Replace(",",",").Replace("、",",").Replace("。",",") & "。"
If s <> chr(10) Then
str &= " " & s.trim & vbcrlf '行首空格
str &= vbcrlf & ""
End If
Next
systemready = False
txt.text = str
systemready = True
End If