按下Command1键选定TEXT1,按下Command1取消TEXT1的选定怎么做
按下Command1键选定TEXT1的内容,按下Command1取消TEXT1的选定的内容怎么做。。求具体代码```````...
按下Command1键选定TEXT1的内容,按下Command1取消TEXT1的选定的内容怎么做。。
求具体代码``````` 展开
求具体代码``````` 展开
2个回答
展开全部
Text1.SetFocus
Text1.SelStart = 0
Text1.SelLength = Len(Text1.Text)
这是选定.
取消.
text1.sellength=0
Text1.SelStart = 0
Text1.SelLength = Len(Text1.Text)
这是选定.
取消.
text1.sellength=0
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
Private Sub Command1_Click()
Static IsSelect As Boolean
IsSelect = Not IsSelect
If IsSelect = True Then
Text1.SetFocus
Text1.SelStart = 0
Text1.SelLength = Len(Text1.Text)
Else
Text1.SetFocus
Text1.SelStart = Len(Text1.Text)
End If
End Sub
Static IsSelect As Boolean
IsSelect = Not IsSelect
If IsSelect = True Then
Text1.SetFocus
Text1.SelStart = 0
Text1.SelLength = Len(Text1.Text)
Else
Text1.SetFocus
Text1.SelStart = Len(Text1.Text)
End If
End Sub
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询