7,763
社区成员
发帖
与我相关
我的任务
分享
Private Sub Command1_Click()
Dim tmp() As String, i As Integer
tmp = Split(Text1.Text)
For i = 0 To UBound(tmp)
List1.AddItem tmp(i)
Next
For i = 0 To List1.ListCount - 1
tmp(i) = List1.List(i)
Next
Text1.Text = Join(tmp, " ")
List1.Clear
End Sub
Private Sub Form_Load()
List1.Visible = False
Text1.Text = "This example adds a centered tab stop to all the paragraphs in the selection"
End Sub
Private Sub Command1_Click()
Dim tmp() As String, i As Integer
tmp = Split(Text1.Text)
For i = 0 To UBound(tmp)
List1.AddItem tmp(i)
Next
For i = 0 To List1.ListCount - 1
tmp(i) = List1.List(i)
Next
Text1.Text = Join(tmp, " ")
End Sub
Private Sub Form_Load()
List1.Visible = False
Text1.Text = "This example adds a centered tab stop to all the paragraphs in the selection"
End Sub
'设计时设置list1的Sorted属性为true(运行时不可改变)
'特殊情况自己处理,比如单词间有两个空格等
'单command1看结果
Private Sub Command1_Click()
Dim tmp() As String, i As Integer
Dim tmmp As String
tmp = Split(Text1.Text)
For i = 0 To UBound(tmp)
List1.AddItem tmp(i)
Next
For i = 0 To List1.ListCount - 1
tmmp = tmmp & List1.List(i) & " "
Next
Text1.Text = tmmp
End Sub
Private Sub Form_Load()
List1.Visible = False
Text1.Text = "This example adds a centered tab stop to all the paragraphs in the selection"
End Sub