按钮上的填充文本框单击

时间:2013-03-31 10:09:15

标签: vb.net

单击Button1时,如何在RichTextbox1中显示一些文本?

1 个答案:

答案 0 :(得分:0)

您可以订阅按钮的Click事件,然后设置richtextbox的Text属性:

Public Sub Button1_Click(ByVal sender As Object, ByVal args As EventArgs) Handles Button1.Click
    RichTextbox1.Text = "This is the text"
End Sub