像Notes一样在标签中显示文本

时间:2015-11-28 07:45:37

标签: vb.net user-interface

在我的应用程序中,我需要在标签中显示一些简短的笔记。

所以我试过这个

lable1.Text="HELP : " & vbNewLine & vbNewLine & "1. You can Remove or
Replace existing Main Icons" & vbNewLine & vbNewLine _
& "2. If you want to remove any buttons, Right click on Icon and 
select UNPIN or select the " _
& " Icon and press delete button from key borad" & vbNewLine & 
vbNewLine & "3. Drag the needed button from top menu and drop it on 
empty space in Icons." & vbNewLine & vbNewLine & "4. If Reports 
having sub reports, You can drag and drop the sub reports only."

如果分数从第2行开始,它从2开始,但我需要所有字母开始像这样的水平

1 . aaaa 2. bbbbb vvvvv

Help必须加下划线。怎么做。可以说哪个控件对此有好处也可以给出一些例子。 我正在使用VB.Net 2008

1 个答案:

答案 0 :(得分:0)

我认为您不能在标签中设置标签,因此您可能需要使用等宽字体手动分隔文本。但是在richtextbox中,你可以这样做。

   RichTextBox1.Text = "HELP : " & vbNewLine & vbNewLine &
"1." & vbTab & "You can Remove or Replace existing Main Icons" & vbNewLine & vbNewLine &
"2." & vbTab & "If you want to remove any buttons, Right click on Icon and" & vbNewLine _
 & vbTab & "select UNPIN or select the Icon and press delete button from keyboard" & vbNewLine & vbNewLine &
 "3." & vbTab & "Drag the needed button from top menu and drop it on" & vbNewLine _
 & vbTab & "empty space in Icons." & vbNewLine & vbNewLine &
 "4." & vbTab & "If Reports having sub reports, You can drag and drop the sub reports only."
    RichTextBox1.SelectAll()
    RichTextBox1.SelectionTabs = {20}
    RichTextBox1.DeselectAll