Share via


.NET Samples - Windows Forms: Control Reference

This section includes the following samples:

UpDown Control Sample

ListBox Control Sample

LinkLabel Sample

Button Control Sample

TreeView Control Sample

ProgressBar Control Sample

TrackBar Control Sample

DateTimePicker Sample

ComboBox Control Sample

CheckedListBox Control Sample

StatusBar Control Sample

ScrollBar Control Sample

ToolTipCtl Sample

TabControl Control Sample

UpDown Control Sample

This sample demonstrates the use of the Windows Forms DomainUpDown and NumericUpDown controls.

Namespaces used in this sample:

System; System.Drawing; System.Windows.Forms; System.ComponentModel; System.Collections

Classes used in this sample:

Form; NumericUpDown; DomainUpDown; Control; String; Object; Label; EventHandler; EventArgs; Component; CheckBox; GroupBox; Group; Container; Application; ComboBox; Thread; Array

ListBox Control Sample

This sample demonstrates the use of the Windows Forms ListBox control.

Namespaces used in this sample:

System; System.Drawing; System.Windows.Forms; System.ComponentModel; System.Resources

Classes used in this sample:

ComboBox; Form; CheckBox; Image; Style; Button; GC; ListBox; Panel; Control; EventArgs; ToolTip; EventHandler; ColorDialog; Label; Component; Object; Bitmap; String; Graphics; SystemColors; DropDownList; Brush; Container; GroupBox; SolidBrush; NumericUpDown; Group; ImageList; ResourceManager; Font; Pen; Thread; SystemPens; DrawItemEventArgs; Pens; Application; MeasureItemEventHandler; PaintEventArgs; DrawItemEventHandler; MeasureItemEventArgs

LinkLabel Sample

This sample demonstrates the use of the Windows Forms LinkLabel control.

Namespaces used in this sample:

System; System.Drawing; System.Windows.Forms; System.ComponentModel; System.Resources

Classes used in this sample:

Label; Form; LinkLabel; Style; Control; Font; Component; Image; Object; Group; GroupBox; Panel; ResourceManager; PropertyGrid; Container; LinkClickedEventHandler; LinkClickedEventArgs; EventArgs; LinkLabelLinkClickedEventHandler; Thread; Message; LinkLabelLinkClickedEventArgs; MessageBox; EventHandler; FontFamily; Application

Button Control Sample

This sample demonstrates the use of the Windows Forms Button control.

Namespaces used in this sample:

System; System.Drawing; System.Windows.Forms; System.ComponentModel; System.Resources; System.Collections

Classes used in this sample:

Image; Form; Style; Object; String; Button; Control; ComboBox; Component; EventArgs; EventHandler; ResourceManager; Label; CheckBox; DropDownList; Container; Group; Panel; GroupBox; Message; Application; Thread; MessageBox; Icon

TreeView Control Sample

This sample demonstrates the use of the Windows Forms TreeView control.

Namespaces used in this sample:

System; System.Drawing; System.Windows.Forms; System.ComponentModel; System.Resources; System.Runtime.InteropServices; System.IO

Classes used in this sample:

Form; TreeView; CheckBox; ComboBox; Directory; Image; Control; EventArgs; EventHandler; ToolTip; ImageList; Stream; Component; TreeNode; Path; Label; DirectoryInfo; Array; Object; Group; GroupBox; Message; Service; SystemColors; Container; ResourceManager; ImageListStreamer; NumericUpDown; Type; CancelEventHandler; Environment; TreeViewCancelEventHandler; TreeViewCancelEventArgs; Import; Thread; Exception; CancelEventArgs; Application; TreeViewEventArgs; MessageBox; TreeViewEventHandler; String; File

ProgressBar Control Sample

This sample demonstrates the use of the Windows Forms ProgressBar control.

Namespaces used in this sample:

System; System.Drawing; System.Windows.Forms; System.ComponentModel; System.Threading; System.Collections

Classes used in this sample:

Form; Control; Label; ProgressBar; Thread; Component; Style; TrackBar; ComboBox; EventArgs; String; Exception; Group; GroupBox; SystemColors; EventHandler; Container; MethodInvoker; ThreadInterruptedException; Message; DropDownList; Math; ThreadStart; Application; Icon; MessageBox

TrackBar Control Sample

This sample demonstrates the use of the Windows Forms TrackBar control.

Namespaces used in this sample:

System; System.Windows.Forms; System.Drawing; System.ComponentModel

Classes used in this sample:

Form; Style; ComboBox; Control; Label; String; EventArgs; TrackBar; EventHandler; DropDownList; Component; Convert; FormatException; Exception; ToolTip; GroupBox; Container; SystemColors; Group; Application; Thread; KeyPressEventArgs

DateTimePicker Sample

This sample demonstrates the use of the Windows Forms DateTimePicker control.

Namespaces used in this sample:

System; System.Windows.Forms; System.Drawing; System.ComponentModel

Classes used in this sample:

Form; Style; Control; DateTimePicker; Calendar; Font; Panel; Button; Label; EventArgs; EventHandler; Component; SystemColors; Container; ToolTip; ErrorProvider; ColorDialog; ComboBox; GroupBox; ContainerControl; FontDialog; Icon; Group; CheckBox; SystemInformation; Thread; DropDownList; String; Application

ComboBox Control Sample

This sample demonstrates the use of the Windows Forms ComboBox control.

Namespaces used in this sample:

System; System.Windows.Forms; System.Drawing; System.ComponentModel; System.Drawing.Drawing2D; System.ComponentModel.Design; System.Collections

Classes used in this sample:

Form; ComboBox; Style; Brush; String; Object; Label; Brushes; EventHandler; EventArgs; ToolTip; SolidBrush; Control; Component; CheckBox; DropDownList; Random; Graphics; Container; Hash; Group; GroupBox; Panel; MeasureItemEventHandler; DrawItemEventHandler; ListBox; Hashtable; MeasureItemEventArgs; Math; Font; Thread; Pen; LinearGradientBrush; DrawItemEventArgs; Exception; Icon; PaintEventArgs; PaintEventHandler; FormatException; Application

CheckedListBox Control Sample

This sample demonstrates the use of the Windows Forms CheckedListBox control.

Namespaces used in this sample:

System; System.Windows.Forms; System.Drawing; System.ComponentModel; System.Resources

Classes used in this sample:

ListBox; Form; CheckBox; Control; CheckedListBox; EventHandler; EventArgs; Button; Component; ToolTip; ListItem; Container; GroupBox; Group; Application; Thread

StatusBar Control Sample

This sample demonstrates the use of the Windows Forms StatusBar control.

Namespaces used in this sample:

System; System.Windows.Forms; System.Drawing; System.ComponentModel; System.Resources; System.Collections

Classes used in this sample:

Panel; Form; StatusBar; Control; StatusBarPanel; Style; EventHandler; Label; EventArgs; ToolTip; Group; ComboBox; Component; GroupBox; KeyEventHandler; SystemColors; Timer; CheckBox; Icon; TrackBar; ResourceManager; Container; DropDownList; String; KeyEventArgs; Thread; Application; Object

ScrollBar Control Sample

This sample demonstrates the use of the Windows Forms ScrollBar control.

Namespaces used in this sample:

System; System.Windows.Forms; System.Drawing; System.ComponentModel; System.Resources; System.Collections

Classes used in this sample:

ScrollBar; Form; VScrollBar; HScrollBar; Label; Control; String; Convert; EventHandler; EventArgs; Component; ComboBox; Image; Style; MouseEventArgs; MouseEventHandler; PictureBox; DropDownList; Group; ScrollEventArgs; GroupBox; Container; ResourceManager; ScrollEventHandler; Cursor; Cursors; Application; Thread; Icon; Object

ToolTipCtl Sample

This sample demonstrates the use of the Windows Forms ToolTip control.

Namespaces used in this sample:

System; System.Windows.Forms; System.Drawing; System.ComponentModel; System.Resources; System.Diagnostics

Classes used in this sample:

Form; Button; ToolTip; Control; Image; Label; PictureBox; ComboBox; Style; Component; ToolBar; EventHandler; ToolBarButton; ImageList; RadioButton; EventArgs; ListView; Group; GroupBox; SystemColors; Container; FormatException; DropDownList; Exception; Debug; Stream; ResourceManager; ListViewItem; Panel; Header; ColumnHeader; LabelEditEventArgs; Object; ImageListStreamer; Application; Thread; LabelEditEventHandler; Help

TabControl Control Sample

This sample demonstrates the use of the Windows Forms TabControl and TabPage controls.

Namespaces used in this sample:

System; System.Windows.Forms; System.Drawing; System.Resources; System.ComponentModel; System.Collections

Classes used in this sample:

ComboBox; Form; Control; Group; GroupBox; Button; Page; RadioButton; Label; Image; DomainUpDown; TabPage; TabControl; Style; EventArgs; EventHandler; ToolTip; ImageList; CheckBox; Object; Component; Bitmap; TrackBar; Stream; PictureBox; DropDownList; ResourceManager; SystemColors; NumericUpDown; Container; UserControl; Screen; Application; Icon; ImageListStreamer; Thread