_
Delad sub Form1 ( ) ) katalog
End Sub
Private Sub InitializeComponent ( ) katalog
listBox1 = Ny System.Windows.Forms.ListBox ( ) katalog
SuspendLayout ( )
"
" listBox1
"
listBox1.FormattingEnabled = Sant
listBox1.HorizontalScrollbar = Sant
listBox1.Items.AddRange ( New Object ( ) { " Punkt 1 , kolumn 1 " ,
" Punkt 2 , kolumn 1 " , " punkt 3 , kolumn 1 " , " punkt 4 , kolumn 1 " , " Punkt
5 , kolumn 1 " , " punkt 1 , kolumn 2 " , " 2 artiklar , kolumn 2 " , " 3 artiklar ,
kolumn 2 " } ) katalog
listBox1.Location = Ny System.Drawing.Point ( 0 , 0 ) katalog
listBox1.MultiColumn = Sant
listBox1.Name = " listBox1 "
listBox1.ScrollAlwaysVisible = Sant
listBox1.Size = Ny System.Drawing.Size ( 120 , 95 ) katalog
listBox1.TabIndex = 0
listBox1.ColumnWidth = 85
"
" Form1
"
ClientSize = Ny System.Drawing.Size ( 292 , 273 ) katalog
Controls.Add ( listBox1 ) katalog
Name = " Form1 "
ResumeLayout ( False ) katalog
End Sub
End Class
4
Klicka på " File" och sedan " Spara " för att lägga till kolumner i listrutan kontrollen i din C # -program .