CheckedListBox Class

Definition

Displays a ListBox in which a check box is displayed to the left of each item.

[System.ComponentModel.LookupBindingProperties]
[System.Runtime.InteropServices.ClassInterface(System.Runtime.InteropServices.ClassInterfaceType.AutoDispatch)]
[System.Runtime.InteropServices.ComVisible(true)]
public class CheckedListBox : System.Windows.Forms.ListBox
Inheritance
Attributes

Examples

The following example illustrates how you can use the methods, properties, and collections of a CheckedListBox. This is a complete sample ready to run once you have copied it to your project. You can check and uncheck items, use the text box to add items and once you have clicked the save button, clear the checked items.

#using <System.Data.dll>
#using <System.Windows.Forms.dll>
#using <System.dll>
#using <System.Drawing.dll>

using namespace System;
using namespace System::Drawing;
using namespace System::Collections;
using namespace System::ComponentModel;
using namespace System::Windows::Forms;
using namespace System::Data;
using namespace System::IO;

public ref class Form1: public System::Windows::Forms::Form
{
private:
   System::Windows::Forms::CheckedListBox^ checkedListBox1;
   System::Windows::Forms::TextBox^ textBox1;
   System::Windows::Forms::Button^ button1;
   System::Windows::Forms::Button^ button2;
   System::Windows::Forms::ListBox^ listBox1;
   System::Windows::Forms::Button^ button3;
   System::ComponentModel::Container^ components;

public:
   Form1()
   {
      InitializeComponent();
      
      // Sets up the initial objects in the CheckedListBox.
      array<String^>^myFruit = {"Apples","Oranges","Tomato"};
      checkedListBox1->Items->AddRange( myFruit );
      
      // Changes the selection mode from double-click to single click.
      checkedListBox1->CheckOnClick = true;
   }

public:
   ~Form1()
   {
      if ( components != nullptr )
      {
         delete components;
      }
   }

private:
   void InitializeComponent()
   {
      this->components = gcnew System::ComponentModel::Container;
      this->textBox1 = gcnew System::Windows::Forms::TextBox;
      this->checkedListBox1 = gcnew System::Windows::Forms::CheckedListBox;
      this->listBox1 = gcnew System::Windows::Forms::ListBox;
      this->button1 = gcnew System::Windows::Forms::Button;
      this->button2 = gcnew System::Windows::Forms::Button;
      this->button3 = gcnew System::Windows::Forms::Button;
      this->textBox1->Location = System::Drawing::Point( 144, 64 );
      this->textBox1->Size = System::Drawing::Size( 128, 20 );
      this->textBox1->TabIndex = 1;
      this->textBox1->TextChanged += gcnew System::EventHandler( this, &Form1::textBox1_TextChanged );
      this->checkedListBox1->Location = System::Drawing::Point( 16, 64 );
      this->checkedListBox1->Size = System::Drawing::Size( 120, 184 );
      this->checkedListBox1->TabIndex = 0;
      this->checkedListBox1->ItemCheck += gcnew System::Windows::Forms::ItemCheckEventHandler( this, &Form1::checkedListBox1_ItemCheck );
      this->listBox1->Location = System::Drawing::Point( 408, 64 );
      this->listBox1->Size = System::Drawing::Size( 128, 186 );
      this->listBox1->TabIndex = 3;
      this->button1->Enabled = false;
      this->button1->Location = System::Drawing::Point( 144, 104 );
      this->button1->Size = System::Drawing::Size( 104, 32 );
      this->button1->TabIndex = 2;
      this->button1->Text = "Add Fruit";
      this->button1->Click += gcnew System::EventHandler( this, &Form1::button1_Click );
      this->button2->Enabled = false;
      this->button2->Location = System::Drawing::Point( 288, 64 );
      this->button2->Size = System::Drawing::Size( 104, 32 );
      this->button2->TabIndex = 2;
      this->button2->Text = "Show Order";
      this->button2->Click += gcnew System::EventHandler( this, &Form1::button2_Click );
      this->button3->Enabled = false;
      this->button3->Location = System::Drawing::Point( 288, 104 );
      this->button3->Size = System::Drawing::Size( 104, 32 );
      this->button3->TabIndex = 2;
      this->button3->Text = "Save Order";
      this->button3->Click += gcnew System::EventHandler( this, &Form1::button3_Click );
      this->ClientSize = System::Drawing::Size( 563, 273 );
      array<System::Windows::Forms::Control^>^temp0 = {this->listBox1,this->button3,this->button2,this->button1,this->textBox1,this->checkedListBox1};
      this->Controls->AddRange( temp0 );
      this->Text = "Fruit Order";
   }

   // Adds the string if the text box has data in it.
   void button1_Click( Object^ /*sender*/, System::EventArgs^ /*e*/ )
   {
      if (  !textBox1->Text->Equals( "" ) )
      {
         if ( checkedListBox1->CheckedItems->Contains( textBox1->Text ) == false )
                  checkedListBox1->Items->Add( textBox1->Text, CheckState::Checked );
         textBox1->Text = "";
      }
   }

   // Activates or deactivates the Add button.
   void textBox1_TextChanged( Object^ /*sender*/, System::EventArgs^ /*e*/ )
   {
      if ( textBox1->Text->Equals( "" ) )
      {
         button1->Enabled = false;
      }
      else
      {
         button1->Enabled = true;
      }
   }

   // Moves the checked items from the CheckedListBox to the listBox.
   void button2_Click( Object^ /*sender*/, System::EventArgs^ /*e*/ )
   {
      listBox1->Items->Clear();
      button3->Enabled = false;
      for ( int i = 0; i < checkedListBox1->CheckedItems->Count; i++ )
      {
         listBox1->Items->Add( checkedListBox1->CheckedItems[ i ] );

      }
      if ( listBox1->Items->Count > 0 )
            button3->Enabled = true;
   }

   // Activates the move button if there are checked items.
   void checkedListBox1_ItemCheck( Object^ /*sender*/, ItemCheckEventArgs^ e )
   {
      if ( e->NewValue == CheckState::Unchecked )
      {
         if ( checkedListBox1->CheckedItems->Count == 1 )
         {
            button2->Enabled = false;
         }
      }
      else
      {
         button2->Enabled = true;
      }
   }

   // Saves the items to a file.
   void button3_Click( Object^ /*sender*/, System::EventArgs^ /*e*/ )
   {
      // Insert code to save a file.
      listBox1->Items->Clear();
      IEnumerator^ myEnumerator;
      myEnumerator = checkedListBox1->CheckedIndices->GetEnumerator();
      int y;
      while ( myEnumerator->MoveNext() != false )
      {
         y = safe_cast<Int32>(myEnumerator->Current);
         checkedListBox1->SetItemChecked( y, false );
      }

      button3->Enabled = false;
   }
};

[STAThread]
int main()
{
   Application::Run( gcnew Form1 );
}
namespace WindowsApplication1
{
   using System;
   using System.Drawing;
   using System.Collections;
   using System.ComponentModel;
   using System.Windows.Forms;
   using System.Data;
   using System.IO ;

   public class Form1 : System.Windows.Forms.Form
   {
      private System.Windows.Forms.CheckedListBox checkedListBox1;
      private System.Windows.Forms.TextBox textBox1;
      private System.Windows.Forms.Button button1;
      private System.Windows.Forms.Button button2;
      private System.Windows.Forms.ListBox listBox1;
      private System.Windows.Forms.Button button3;
        private System.ComponentModel.Container components;
      
      public Form1()
      {
            InitializeComponent();

         // Sets up the initial objects in the CheckedListBox.
            string[] myFruit = {"Apples", "Oranges","Tomato"};
         checkedListBox1.Items.AddRange(myFruit);

            // Changes the selection mode from double-click to single click.
         checkedListBox1.CheckOnClick = true;
      }

      protected override void Dispose( bool disposing )
	  {
		if( disposing )
		{
			if (components != null) 
			{
			  components.Dispose();
			}
		}
		base.Dispose( disposing );
	  }

      private void InitializeComponent()
      {
         this.components = new System.ComponentModel.Container();
         this.textBox1 = new System.Windows.Forms.TextBox();
         this.checkedListBox1 = new System.Windows.Forms.CheckedListBox();
         this.listBox1 = new System.Windows.Forms.ListBox();
         this.button1 = new System.Windows.Forms.Button();
         this.button2 = new System.Windows.Forms.Button();
         this.button3 = new System.Windows.Forms.Button();
         this.textBox1.Location = new System.Drawing.Point(144, 64);
         this.textBox1.Size = new System.Drawing.Size(128, 20);
         this.textBox1.TabIndex = 1;
         this.textBox1.TextChanged += new System.EventHandler(this.textBox1_TextChanged);
         this.checkedListBox1.Location = new System.Drawing.Point(16, 64);
         this.checkedListBox1.Size = new System.Drawing.Size(120, 184);
         this.checkedListBox1.TabIndex = 0;
         this.checkedListBox1.ItemCheck += new System.Windows.Forms.ItemCheckEventHandler(this.checkedListBox1_ItemCheck);
         this.listBox1.Location = new System.Drawing.Point(408, 64);
         this.listBox1.Size = new System.Drawing.Size(128, 186);
         this.listBox1.TabIndex = 3;
         this.button1.Enabled = false;
         this.button1.Location = new System.Drawing.Point(144, 104);
         this.button1.Size = new System.Drawing.Size(104, 32);
         this.button1.TabIndex = 2;
         this.button1.Text = "Add Fruit";
         this.button1.Click += new System.EventHandler(this.button1_Click);
         this.button2.Enabled = false;
         this.button2.Location = new System.Drawing.Point(288, 64);
         this.button2.Size = new System.Drawing.Size(104, 32);
         this.button2.TabIndex = 2;
         this.button2.Text = "Show Order";
         this.button2.Click += new System.EventHandler(this.button2_Click);
         this.button3.Enabled = false;
         this.button3.Location = new System.Drawing.Point(288, 104);
         this.button3.Size = new System.Drawing.Size(104, 32);
         this.button3.TabIndex = 2;
         this.button3.Text = "Save Order";
         this.button3.Click += new System.EventHandler(this.button3_Click);
         this.ClientSize = new System.Drawing.Size(563, 273);
         this.Controls.AddRange(new System.Windows.Forms.Control[] {this.listBox1,
                                                        this.button3,
                                                        this.button2,
                                                        this.button1,
                                                        this.textBox1,
                                                        this.checkedListBox1});
         this.Text = "Fruit Order";
      }

      [STAThread]
      public static void Main(string[] args) 
      {
         Application.Run(new Form1());
      }

      // Adds the string if the text box has data in it.
      private void button1_Click(object sender, System.EventArgs e)
      {
         if(textBox1.Text != "")
         {
            if(checkedListBox1.CheckedItems.Contains(textBox1.Text)== false)
               checkedListBox1.Items.Add(textBox1.Text,CheckState.Checked);
            textBox1.Text = "";
         }

      }
      // Activates or deactivates the Add button.
      private void textBox1_TextChanged(object sender, System.EventArgs e)
      {
         if (textBox1.Text == "")
         {
            button1.Enabled = false;
         }
         else
         {
            button1.Enabled = true;
         }
            
        }

      // Moves the checked items from the CheckedListBox to the listBox.
      private void button2_Click(object sender, System.EventArgs e)
      {
         listBox1.Items.Clear();
         button3.Enabled=false;
         for (int i=0; i< checkedListBox1.CheckedItems.Count;i++)
         {
            listBox1.Items.Add(checkedListBox1.CheckedItems[i]);
         }
         if (listBox1.Items.Count>0)
            button3.Enabled=true;
         
      }
        // Activates the move button if there are checked items.
      private void checkedListBox1_ItemCheck(object sender, ItemCheckEventArgs e)
      {
         if(e.NewValue==CheckState.Unchecked)
         {
            if(checkedListBox1.CheckedItems.Count==1)
            {
               button2.Enabled = false;
            }
         }
         else
         {
            button2.Enabled = true;
         }
      }

        // Saves the items to a file.
      private void button3_Click(object sender, System.EventArgs e)
      {   
         // Insert code to save a file.
         listBox1.Items.Clear();
         IEnumerator myEnumerator;
         myEnumerator = checkedListBox1.CheckedIndices.GetEnumerator();
         int y;
         while (myEnumerator.MoveNext() != false)
         {
            y =(int) myEnumerator.Current;
            checkedListBox1.SetItemChecked(y, false);
         }
         button3.Enabled = false ;
      }        
    }
}
   
Option Explicit
Option Strict

Imports System
Imports System.Drawing
Imports System.Collections
Imports System.ComponentModel
Imports System.Windows.Forms
Imports System.Data
Imports System.IO

Namespace WindowsApplication1
    Public Class Form1
        Inherits System.Windows.Forms.Form
        Private WithEvents checkedListBox1 As System.Windows.Forms.CheckedListBox
        Private WithEvents textBox1 As System.Windows.Forms.TextBox
        Private WithEvents button1 As System.Windows.Forms.Button
        Private WithEvents button2 As System.Windows.Forms.Button
        Private WithEvents listBox1 As System.Windows.Forms.ListBox
        Private WithEvents button3 As System.Windows.Forms.Button
        Private components As System.ComponentModel.Container
        
        
        Public Sub New()
            InitializeComponent()
            
            ' Sets up the initial objects in the CheckedListBox.
            Dim myFruit As String() =  {"Apples", "Oranges", "Tomato"}
            checkedListBox1.Items.AddRange(myFruit)
            
            ' Changes the selection mode from double-click to single click.
            checkedListBox1.CheckOnClick = True
        End Sub 'New
        
        
        Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
            If disposing Then
                If (components IsNot Nothing) Then
                    components.Dispose()
                End If
            End If
            MyBase.Dispose(disposing)
        End Sub
         
        Private Sub InitializeComponent()
            Me.components = New System.ComponentModel.Container()
            Me.textBox1 = New System.Windows.Forms.TextBox()
            Me.checkedListBox1 = New System.Windows.Forms.CheckedListBox()
            Me.listBox1 = New System.Windows.Forms.ListBox()
            Me.button1 = New System.Windows.Forms.Button()
            Me.button2 = New System.Windows.Forms.Button()
            Me.button3 = New System.Windows.Forms.Button()
            Me.textBox1.Location = New System.Drawing.Point(144, 64)
            Me.textBox1.Size = New System.Drawing.Size(128, 20)
            Me.textBox1.TabIndex = 1
            Me.checkedListBox1.Location = New System.Drawing.Point(16, 64)
            Me.checkedListBox1.Size = New System.Drawing.Size(120, 184)
            Me.checkedListBox1.TabIndex = 0
            Me.listBox1.Location = New System.Drawing.Point(408, 64)
            Me.listBox1.Size = New System.Drawing.Size(128, 186)
            Me.listBox1.TabIndex = 3
            Me.button1.Enabled = False
            Me.button1.Location = New System.Drawing.Point(144, 104)
            Me.button1.Size = New System.Drawing.Size(104, 32)
            Me.button1.TabIndex = 2
            Me.button1.Text = "Add Fruit"
            Me.button2.Enabled = False
            Me.button2.Location = New System.Drawing.Point(288, 64)
            Me.button2.Size = New System.Drawing.Size(104, 32)
            Me.button2.TabIndex = 2
            Me.button2.Text = "Show Order"
            Me.button3.Enabled = False
            Me.button3.Location = New System.Drawing.Point(288, 104)
            Me.button3.Size = New System.Drawing.Size(104, 32)
            Me.button3.TabIndex = 2
            Me.button3.Text = "Save Order"
            Me.ClientSize = New System.Drawing.Size(563, 273)
            Me.Controls.AddRange(New System.Windows.Forms.Control() {Me.listBox1, Me.button3, Me.button2, Me.button1, Me.textBox1, Me.checkedListBox1})
            Me.Text = "Fruit Order"
        End Sub 'InitializeComponent
        
        <STAThread()> _
        Public Shared Sub Main()
            Application.Run(New Form1())
        End Sub 'Main
        
        
        ' Adds the string if the text box has data in it.
        Private Sub button1_Click(sender As Object, _
                e As System.EventArgs) Handles button1.Click
            If textBox1.Text <> "" Then
                If checkedListBox1.CheckedItems.Contains(textBox1.Text) = False Then
                    checkedListBox1.Items.Add(textBox1.Text, CheckState.Checked)
                End If
                textBox1.Text = ""
            End If
        End Sub 'button1_Click
         
        ' Activates or deactivates the Add button.
        Private Sub textBox1_TextChanged(sender As Object, _
                e As System.EventArgs) Handles textBox1.TextChanged
            If textBox1.Text = "" Then
                button1.Enabled = False
            Else
                button1.Enabled = True
            End If
        End Sub 'textBox1_TextChanged
         
        
        ' Moves the checked items from the CheckedListBox to the listBox.
        Private Sub button2_Click(sender As Object, _
                e As System.EventArgs) Handles button2.Click
            listBox1.Items.Clear()
            button3.Enabled = False
            Dim i As Integer
            For i = 0 To checkedListBox1.CheckedItems.Count - 1
                listBox1.Items.Add(checkedListBox1.CheckedItems(i))
            Next i
            If listBox1.Items.Count > 0 Then
                button3.Enabled = True
            End If 
        End Sub 'button2_Click
        
        ' Activates the move button if there are checked items.
        Private Sub checkedListBox1_ItemCheck(sender As Object, _
                e As ItemCheckEventArgs) Handles checkedListBox1.ItemCheck
            If e.NewValue = CheckState.Unchecked Then
                If checkedListBox1.CheckedItems.Count = 1 Then
                    button2.Enabled = False
                End If
            Else
                button2.Enabled = True
            End If
        End Sub 'checkedListBox1_ItemCheck
        
        
        ' Saves the items to a file.
        Private Sub button3_Click(sender As Object, _
                e As System.EventArgs) Handles button3.Click
            ' Insert code to save a file.
            listBox1.Items.Clear()
            Dim myEnumerator As IEnumerator
            myEnumerator = checkedListBox1.CheckedIndices.GetEnumerator()
            Dim y As Integer
            While myEnumerator.MoveNext() <> False
                y = CInt(myEnumerator.Current)
                checkedListBox1.SetItemChecked(y, False)
            End While
            button3.Enabled = False
        End Sub 'button3_Click
    End Class 'Form1
End Namespace 'WindowsApplication1

Remarks

This control presents a list of items that the user can navigate by using the keyboard or the scrollbar on the right side of the control. The user can place a check mark by one or more items and the checked items can be navigated with the CheckedListBox.CheckedItemCollection and CheckedListBox.CheckedIndexCollection.

To add objects to the list at run time, assign an array of object references with the AddRange method. The list then displays the default string value for each object. You can add individual items to the list with the Add method.

The CheckedListBox object supports three states through the CheckState enumeration: Checked, Indeterminate, and Unchecked. You must set the state of Indeterminate in the code because the user interface for a CheckedListBox does not provide a mechanism to do so.

If UseTabStops is true, the CheckedListBox will recognize and expand tab characters in an item's text, creating columns. These tab stops are preset and cannot be changed. To use custom tab stops, set UseTabStops to false, set UseCustomTabOffsets to true, and add the custom values to the CustomTabOffsets collection.

Note

If the UseCompatibleTextRendering property is false, the CustomTabOffsets property will be ignored and replaced with standard tab offsets.

The CheckedListBox class supports the following three indexed collections:

Collection Encapsulating Class
All items contained in the CheckedListBox control. CheckedListBox.ObjectCollection
Checked items (including items in an indeterminate state), which is a subset of the items contained in the CheckedListBox control. CheckedListBox.CheckedItemCollection
Checked indexes, which is a subset of the indexes into the items collection. These indexes specify items in a checked or indeterminate state. CheckedListBox.CheckedIndexCollection

The following three tables are examples of the three indexed collections that the CheckedListBox class supports.

The first table provides an example of the indexed collection of items in the control (all items contained in the control).

Index Item Check State
0 Object 1 Unchecked
1 Object 2 Checked
2 Object 3 Unchecked
3 Object 4 Indeterminate
4 Object 5 Checked

The second table provides an example of the indexed collection of the checked items.

Index Item
0 Object 2
1 Object 4
2 Object 5

The third table provides an example of the indexed collection of indexes of checked items.

Index Index of Item
0 1
1 3
2 4

Constructors

CheckedListBox()

Initializes a new instance of the CheckedListBox class.

Properties

CheckedIndices

Collection of checked indexes in this CheckedListBox.

CheckedItems

Collection of checked items in this CheckedListBox.

CheckOnClick

Gets or sets a value indicating whether the check box should be toggled when an item is selected.

CreateParams

Gets the required creation parameters when the control handle is created.

DataSource

Gets or sets the data source for the control.

DisplayMember

Gets or sets a string that specifies a property of the objects contained in the list box whose contents you want to display.

DrawMode

Gets a value indicating the mode for drawing elements of the CheckedListBox. This property is not relevant to this class.

ItemHeight

Gets the height of the item area.

Items

Gets the collection of items in this CheckedListBox.

Padding

Gets or sets padding within the CheckedListBox. This property is not relevant to this class.

SelectionMode

Gets or sets a value specifying the selection mode.

ThreeDCheckBoxes

Gets or sets a value indicating whether the check boxes have a ButtonState of Flat or Normal.

UseCompatibleTextRendering

Gets or sets a value that determines whether to use the Graphics class (GDI+) or the TextRenderer class (GDI) to render text.

ValueMember

Gets or sets a string that specifies the property of the data source from which to draw the value.

Methods

CreateAccessibilityInstance()

Creates a new accessibility object for the CheckedListBox control.

CreateItemCollection()

Creates a new instance of the item collection.

GetItemChecked(Int32)

Returns a value indicating whether the specified item is checked.

GetItemCheckState(Int32)

Returns a value indicating the check state of the current item.

OnBackColorChanged(EventArgs)

Raises the BackColorChanged event.

OnClick(EventArgs)

Raises the Click event.

OnDrawItem(DrawItemEventArgs)

Raises the DrawItem event.

OnFontChanged(EventArgs)

Raises the FontChanged event.

OnHandleCreated(EventArgs)

Raises the HandleCreated event.

OnItemCheck(ItemCheckEventArgs)

Raises the ItemCheck event.

OnKeyPress(KeyPressEventArgs)

Raises the KeyPress event.

OnMeasureItem(MeasureItemEventArgs)

Raises the MeasureItem event.

OnSelectedIndexChanged(EventArgs)

Raises the SelectedIndexChanged event.

RefreshItems()

Parses all CheckedListBox items again and gets new text strings for the items.

SetItemChecked(Int32, Boolean)

Sets CheckState for the item at the specified index to Checked.

SetItemCheckState(Int32, CheckState)

Sets the check state of the item at the specified index.

WmReflectCommand(Message)

Processes the command message the CheckedListBox control receives from the top-level window.

WndProc(Message)

Processes Windows messages.

Container Inherited from Component
DesignMode Inherited from Component
Dispose() Inherited from Component
Disposed Inherited from Component
Events Inherited from Component
GetService(Type) Inherited from Component
CreateObjRef(Type) Inherited from MarshalByRefObject
GetLifetimeService() Inherited from MarshalByRefObject
InitializeLifetimeService() Inherited from MarshalByRefObject
MemberwiseClone(Boolean) Inherited from MarshalByRefObject
Equals(Object) Inherited from Object
Equals(Object, Object) Inherited from Object
GetHashCode() Inherited from Object
GetType() Inherited from Object
MemberwiseClone() Inherited from Object
ReferenceEquals(Object, Object) Inherited from Object
AccessibilityNotifyClients(AccessibleEvents, Int32) Inherited from Control
AccessibilityNotifyClients(AccessibleEvents, Int32, Int32) Inherited from Control
AccessibilityObject Inherited from Control
AccessibleDefaultActionDescription Inherited from Control
AccessibleDescription Inherited from Control
AccessibleName Inherited from Control
AccessibleRole Inherited from Control
AllowDrop Inherited from Control
Anchor Inherited from Control
AutoScrollOffset Inherited from Control
AutoSize Inherited from Control
AutoSizeChanged Inherited from Control
BackColorChanged Inherited from Control
BeginInvoke(Delegate) Inherited from Control
BeginInvoke(Delegate, Object[]) Inherited from Control
BindingContext Inherited from Control
BindingContextChanged Inherited from Control
Bottom Inherited from Control
Bounds Inherited from Control
BringToFront() Inherited from Control
CanEnableIme Inherited from Control
CanFocus Inherited from Control
CanRaiseEvents Inherited from Control
CanSelect Inherited from Control
Capture Inherited from Control
CausesValidation Inherited from Control
CausesValidationChanged Inherited from Control
ChangeUICues Inherited from Control
CheckForIllegalCrossThreadCalls Inherited from Control
ClientRectangle Inherited from Control
ClientSize Inherited from Control
ClientSizeChanged Inherited from Control
CompanyName Inherited from Control
Contains(Control) Inherited from Control
ContainsFocus Inherited from Control
ContextMenu Inherited from Control
ContextMenuChanged Inherited from Control
ContextMenuStrip Inherited from Control
ContextMenuStripChanged Inherited from Control
ControlAdded Inherited from Control
ControlRemoved Inherited from Control
Controls Inherited from Control
CreateControl() Inherited from Control
CreateControlsInstance() Inherited from Control
Created Inherited from Control
CreateGraphics() Inherited from Control
CreateHandle() Inherited from Control
Cursor Inherited from Control
CursorChanged Inherited from Control
DataBindings Inherited from Control
DefaultBackColor Inherited from Control
DefaultCursor Inherited from Control
DefaultFont Inherited from Control
DefaultForeColor Inherited from Control
DefaultImeMode Inherited from Control
DefaultMargin Inherited from Control
DefaultMaximumSize Inherited from Control
DefaultMinimumSize Inherited from Control
DefaultPadding Inherited from Control
DefWndProc(Message) Inherited from Control
DestroyHandle() Inherited from Control
DeviceDpi Inherited from Control
DisplayRectangle Inherited from Control
Dispose(Boolean) Inherited from Control
Disposing Inherited from Control
Dock Inherited from Control
DockChanged Inherited from Control
DoDragDrop(Object, DragDropEffects) Inherited from Control
DoubleBuffered Inherited from Control
DoubleClick Inherited from Control
DpiChangedAfterParent Inherited from Control
DpiChangedBeforeParent Inherited from Control
DragDrop Inherited from Control
DragEnter Inherited from Control
DragLeave Inherited from Control
DragOver Inherited from Control
DrawToBitmap(Bitmap, Rectangle) Inherited from Control
Enabled Inherited from Control
EnabledChanged Inherited from Control
EndInvoke(IAsyncResult) Inherited from Control
Enter Inherited from Control
FindForm() Inherited from Control
Focus() Inherited from Control
Focused Inherited from Control
FontChanged Inherited from Control
FontHeight Inherited from Control
ForeColorChanged Inherited from Control
FromChildHandle(IntPtr) Inherited from Control
FromHandle(IntPtr) Inherited from Control
GetAccessibilityObjectById(Int32) Inherited from Control
GetAutoSizeMode() Inherited from Control
GetChildAtPoint(Point) Inherited from Control
GetChildAtPoint(Point, GetChildAtPointSkip) Inherited from Control
GetContainerControl() Inherited from Control
GetNextControl(Control, Boolean) Inherited from Control
GetPreferredSize(Size) Inherited from Control
GetStyle(ControlStyles) Inherited from Control
GetTopLevel() Inherited from Control
GiveFeedback Inherited from Control
GotFocus Inherited from Control
Handle Inherited from Control
HandleCreated Inherited from Control
HandleDestroyed Inherited from Control
HasChildren Inherited from Control
Height Inherited from Control
HelpRequested Inherited from Control
Hide() Inherited from Control
ImeMode Inherited from Control
ImeModeBase Inherited from Control
ImeModeChanged Inherited from Control
InitLayout() Inherited from Control
Invalidate() Inherited from Control
Invalidate(Boolean) Inherited from Control
Invalidate(Rectangle) Inherited from Control
Invalidate(Rectangle, Boolean) Inherited from Control
Invalidate(Region) Inherited from Control
Invalidate(Region, Boolean) Inherited from Control
Invalidated Inherited from Control
Invoke(Delegate) Inherited from Control
Invoke(Delegate, Object[]) Inherited from Control
InvokeGotFocus(Control, EventArgs) Inherited from Control
InvokeLostFocus(Control, EventArgs) Inherited from Control
InvokeOnClick(Control, EventArgs) Inherited from Control
InvokePaint(Control, PaintEventArgs) Inherited from Control
InvokePaintBackground(Control, PaintEventArgs) Inherited from Control
InvokeRequired Inherited from Control
IsAccessible Inherited from Control
IsDisposed Inherited from Control
IsHandleCreated Inherited from Control
IsInputChar(Char) Inherited from Control
IsKeyLocked(Keys) Inherited from Control
IsMirrored Inherited from Control
IsMnemonic(Char, String) Inherited from Control
KeyDown Inherited from Control
KeyPress Inherited from Control
KeyUp Inherited from Control
Layout Inherited from Control
LayoutEngine Inherited from Control
Leave Inherited from Control
Left Inherited from Control
Location Inherited from Control
LocationChanged Inherited from Control
LogicalToDeviceUnits(Int32) Inherited from Control
LostFocus Inherited from Control
Margin Inherited from Control
MarginChanged Inherited from Control
MaximumSize Inherited from Control
MinimumSize Inherited from Control
ModifierKeys Inherited from Control
MouseButtons Inherited from Control
MouseCaptureChanged Inherited from Control
MouseDoubleClick Inherited from Control
MouseDown Inherited from Control
MouseEnter Inherited from Control
MouseHover Inherited from Control
MouseLeave Inherited from Control
MouseMove Inherited from Control
MousePosition Inherited from Control
MouseUp Inherited from Control
MouseWheel Inherited from Control
Move Inherited from Control
Name Inherited from Control
NotifyInvalidate(Rectangle) Inherited from Control
OnAutoSizeChanged(EventArgs) Inherited from Control
OnBackgroundImageChanged(EventArgs) Inherited from Control
OnBackgroundImageLayoutChanged(EventArgs) Inherited from Control
OnCausesValidationChanged(EventArgs) Inherited from Control
OnClientSizeChanged(EventArgs) Inherited from Control
OnContextMenuChanged(EventArgs) Inherited from Control
OnContextMenuStripChanged(EventArgs) Inherited from Control
OnControlAdded(ControlEventArgs) Inherited from Control
OnControlRemoved(ControlEventArgs) Inherited from Control
OnCreateControl() Inherited from Control
OnCursorChanged(EventArgs) Inherited from Control
OnDockChanged(EventArgs) Inherited from Control
OnDoubleClick(EventArgs) Inherited from Control
OnDpiChangedAfterParent(EventArgs) Inherited from Control
OnDpiChangedBeforeParent(EventArgs) Inherited from Control
OnDragDrop(DragEventArgs) Inherited from Control
OnDragEnter(DragEventArgs) Inherited from Control
OnDragLeave(EventArgs) Inherited from Control
OnDragOver(DragEventArgs) Inherited from Control
OnEnabledChanged(EventArgs) Inherited from Control
OnEnter(EventArgs) Inherited from Control
OnForeColorChanged(EventArgs) Inherited from Control
OnGiveFeedback(GiveFeedbackEventArgs) Inherited from Control
OnGotFocus(EventArgs) Inherited from Control
OnHelpRequested(HelpEventArgs) Inherited from Control
OnImeModeChanged(EventArgs) Inherited from Control
OnInvalidated(InvalidateEventArgs) Inherited from Control
OnKeyDown(KeyEventArgs) Inherited from Control
OnKeyUp(KeyEventArgs) Inherited from Control
OnLayout(LayoutEventArgs) Inherited from Control
OnLeave(EventArgs) Inherited from Control
OnLocationChanged(EventArgs) Inherited from Control
OnLostFocus(EventArgs) Inherited from Control
OnMarginChanged(EventArgs) Inherited from Control
OnMouseCaptureChanged(EventArgs) Inherited from Control
OnMouseClick(MouseEventArgs) Inherited from Control
OnMouseDoubleClick(MouseEventArgs) Inherited from Control
OnMouseDown(MouseEventArgs) Inherited from Control
OnMouseEnter(EventArgs) Inherited from Control
OnMouseHover(EventArgs) Inherited from Control
OnMouseLeave(EventArgs) Inherited from Control
OnMouseMove(MouseEventArgs) Inherited from Control
OnMouseUp(MouseEventArgs) Inherited from Control
OnMouseWheel(MouseEventArgs) Inherited from Control
OnMove(EventArgs) Inherited from Control
OnNotifyMessage(Message) Inherited from Control
OnPaddingChanged(EventArgs) Inherited from Control
OnPaint(PaintEventArgs) Inherited from Control
OnPaintBackground(PaintEventArgs) Inherited from Control
OnParentBackColorChanged(EventArgs) Inherited from Control
OnParentBackgroundImageChanged(EventArgs) Inherited from Control
OnParentBindingContextChanged(EventArgs) Inherited from Control
OnParentCursorChanged(EventArgs) Inherited from Control
OnParentEnabledChanged(EventArgs) Inherited from Control
OnParentFontChanged(EventArgs) Inherited from Control
OnParentForeColorChanged(EventArgs) Inherited from Control
OnParentRightToLeftChanged(EventArgs) Inherited from Control
OnParentVisibleChanged(EventArgs) Inherited from Control
OnPreviewKeyDown(PreviewKeyDownEventArgs) Inherited from Control
OnPrint(PaintEventArgs) Inherited from Control
OnQueryContinueDrag(QueryContinueDragEventArgs) Inherited from Control
OnRegionChanged(EventArgs) Inherited from Control
OnRightToLeftChanged(EventArgs) Inherited from Control
OnSizeChanged(EventArgs) Inherited from Control
OnStyleChanged(EventArgs) Inherited from Control
OnSystemColorsChanged(EventArgs) Inherited from Control
OnTabIndexChanged(EventArgs) Inherited from Control
OnTabStopChanged(EventArgs) Inherited from Control
OnTextChanged(EventArgs) Inherited from Control
OnValidated(EventArgs) Inherited from Control
OnValidating(CancelEventArgs) Inherited from Control
OnVisibleChanged(EventArgs) Inherited from Control
Parent Inherited from Control
ParentChanged Inherited from Control
PerformLayout() Inherited from Control
PerformLayout(Control, String) Inherited from Control
PointToClient(Point) Inherited from Control
PointToScreen(Point) Inherited from Control
PreferredSize Inherited from Control
PreProcessControlMessage(Message) Inherited from Control
PreProcessMessage(Message) Inherited from Control
PreviewKeyDown Inherited from Control
ProcessCmdKey(Message, Keys) Inherited from Control
ProcessDialogChar(Char) Inherited from Control
ProcessDialogKey(Keys) Inherited from Control
ProcessKeyEventArgs(Message) Inherited from Control
ProcessKeyMessage(Message) Inherited from Control
ProcessKeyPreview(Message) Inherited from Control
ProcessMnemonic(Char) Inherited from Control
ProductName Inherited from Control
ProductVersion Inherited from Control
PropagatingImeMode Inherited from Control
QueryAccessibilityHelp Inherited from Control
QueryContinueDrag Inherited from Control
RaiseDragEvent(Object, DragEventArgs) Inherited from Control
RaiseKeyEvent(Object, KeyEventArgs) Inherited from Control
RaiseMouseEvent(Object, MouseEventArgs) Inherited from Control
RaisePaintEvent(Object, PaintEventArgs) Inherited from Control
RecreateHandle() Inherited from Control
RecreatingHandle Inherited from Control
RectangleToClient(Rectangle) Inherited from Control
RectangleToScreen(Rectangle) Inherited from Control
ReflectMessage(IntPtr, Message) Inherited from Control
Region Inherited from Control
RegionChanged Inherited from Control
RenderRightToLeft Inherited from Control
ResetBindings() Inherited from Control
ResetCursor() Inherited from Control
ResetFont() Inherited from Control
ResetImeMode() Inherited from Control
ResetMouseEventArgs() Inherited from Control
ResetRightToLeft() Inherited from Control
ResetText() Inherited from Control
Resize Inherited from Control
ResizeRedraw Inherited from Control
ResumeLayout() Inherited from Control
ResumeLayout(Boolean) Inherited from Control
Right Inherited from Control
RightToLeftChanged Inherited from Control
RtlTranslateAlignment(ContentAlignment) Inherited from Control
RtlTranslateAlignment(HorizontalAlignment) Inherited from Control
RtlTranslateAlignment(LeftRightAlignment) Inherited from Control
RtlTranslateContent(ContentAlignment) Inherited from Control
RtlTranslateHorizontal(HorizontalAlignment) Inherited from Control
RtlTranslateLeftRight(LeftRightAlignment) Inherited from Control
Scale(SizeF) Inherited from Control
Scale(Single) Inherited from Control
Scale(Single, Single) Inherited from Control
ScaleBitmapLogicalToDevice(Bitmap) Inherited from Control
ScaleChildren Inherited from Control
ScaleCore(Single, Single) Inherited from Control
Select() Inherited from Control
Select(Boolean, Boolean) Inherited from Control
SelectNextControl(Control, Boolean, Boolean, Boolean, Boolean) Inherited from Control
SendToBack() Inherited from Control
SetAutoSizeMode(AutoSizeMode) Inherited from Control
SetBounds(Int32, Int32, Int32, Int32) Inherited from Control
SetBounds(Int32, Int32, Int32, Int32, BoundsSpecified) Inherited from Control
SetClientSizeCore(Int32, Int32) Inherited from Control
SetStyle(ControlStyles, Boolean) Inherited from Control
SetTopLevel(Boolean) Inherited from Control
SetVisibleCore(Boolean) Inherited from Control
Show() Inherited from Control
ShowFocusCues Inherited from Control
ShowKeyboardCues Inherited from Control
Site Inherited from Control
Size Inherited from Control
SizeChanged Inherited from Control
SizeFromClientSize(Size) Inherited from Control
StyleChanged Inherited from Control
SuspendLayout() Inherited from Control
IDropTarget.OnDragDrop(DragEventArgs) Inherited from Control
IDropTarget.OnDragEnter(DragEventArgs) Inherited from Control
IDropTarget.OnDragLeave(EventArgs) Inherited from Control
IDropTarget.OnDragOver(DragEventArgs) Inherited from Control
SystemColorsChanged Inherited from Control
TabIndex Inherited from Control
TabIndexChanged Inherited from Control
TabStop Inherited from Control
TabStopChanged Inherited from Control
Tag Inherited from Control
Top Inherited from Control
TopLevelControl Inherited from Control
Update() Inherited from Control
UpdateBounds() Inherited from Control
UpdateBounds(Int32, Int32, Int32, Int32) Inherited from Control
UpdateBounds(Int32, Int32, Int32, Int32, Int32, Int32) Inherited from Control
UpdateStyles() Inherited from Control
UpdateZOrder() Inherited from Control
UseWaitCursor Inherited from Control
Validated Inherited from Control
Validating Inherited from Control
Visible Inherited from Control
VisibleChanged Inherited from Control
Width Inherited from Control
WindowTarget Inherited from Control
AddItemsCore(Object[]) Inherited from ListBox
AllowSelection Inherited from ListBox
BackColor Inherited from ListBox
BackgroundImage Inherited from ListBox
BackgroundImageChanged Inherited from ListBox
BackgroundImageLayout Inherited from ListBox
BackgroundImageLayoutChanged Inherited from ListBox
BeginUpdate() Inherited from ListBox
BorderStyle Inherited from ListBox
ClearSelected() Inherited from ListBox
ColumnWidth Inherited from ListBox
CustomTabOffsets Inherited from ListBox
DefaultItemHeight Inherited from ListBox
DefaultSize Inherited from ListBox
EndUpdate() Inherited from ListBox
FindString(String) Inherited from ListBox
FindString(String, Int32) Inherited from ListBox
FindStringExact(String) Inherited from ListBox
FindStringExact(String, Int32) Inherited from ListBox
Font Inherited from ListBox
ForeColor Inherited from ListBox
GetItemHeight(Int32) Inherited from ListBox
GetItemRectangle(Int32) Inherited from ListBox
GetScaledBounds(Rectangle, SizeF, BoundsSpecified) Inherited from ListBox
GetSelected(Int32) Inherited from ListBox
HorizontalExtent Inherited from ListBox
HorizontalScrollbar Inherited from ListBox
IndexFromPoint(Point) Inherited from ListBox
IndexFromPoint(Int32, Int32) Inherited from ListBox
IntegralHeight Inherited from ListBox
MultiColumn Inherited from ListBox
NoMatches Inherited from ListBox
OnChangeUICues(UICuesEventArgs) Inherited from ListBox
OnDataSourceChanged(EventArgs) Inherited from ListBox
OnDisplayMemberChanged(EventArgs) Inherited from ListBox
OnHandleDestroyed(EventArgs) Inherited from ListBox
OnParentChanged(EventArgs) Inherited from ListBox
OnResize(EventArgs) Inherited from ListBox
OnSelectedValueChanged(EventArgs) Inherited from ListBox
PaddingChanged Inherited from ListBox
Paint Inherited from ListBox
PreferredHeight Inherited from ListBox
Refresh() Inherited from ListBox
RefreshItem(Int32) Inherited from ListBox
RescaleConstantsForDpi(Int32, Int32) Inherited from ListBox
ResetBackColor() Inherited from ListBox
ResetForeColor() Inherited from ListBox
RightToLeft Inherited from ListBox
ScaleControl(SizeF, BoundsSpecified) Inherited from ListBox
ScrollAlwaysVisible Inherited from ListBox
SelectedIndex Inherited from ListBox
SelectedIndexChanged Inherited from ListBox
SelectedIndices Inherited from ListBox
SelectedItem Inherited from ListBox
SelectedItems Inherited from ListBox
SetBoundsCore(Int32, Int32, Int32, Int32, BoundsSpecified) Inherited from ListBox
SetItemCore(Int32, Object) Inherited from ListBox
SetItemsCore(IList) Inherited from ListBox
SetSelected(Int32, Boolean) Inherited from ListBox
Sort() Inherited from ListBox
Sorted Inherited from ListBox
Text Inherited from ListBox
TextChanged Inherited from ListBox
TopIndex Inherited from ListBox
ToString() Inherited from ListBox
UseCustomTabOffsets Inherited from ListBox
UseTabStops Inherited from ListBox
DataManager Inherited from ListControl
FilterItemOnProperty(Object) Inherited from ListControl
FilterItemOnProperty(Object, String) Inherited from ListControl
Format Inherited from ListControl
FormatInfo Inherited from ListControl
FormatInfoChanged Inherited from ListControl
FormatString Inherited from ListControl
FormatStringChanged Inherited from ListControl
FormattingEnabled Inherited from ListControl
FormattingEnabledChanged Inherited from ListControl
GetItemText(Object) Inherited from ListControl
IsInputKey(Keys) Inherited from ListControl
OnBindingContextChanged(EventArgs) Inherited from ListControl
OnFormat(ListControlConvertEventArgs) Inherited from ListControl
OnFormatInfoChanged(EventArgs) Inherited from ListControl
OnFormatStringChanged(EventArgs) Inherited from ListControl
OnFormattingEnabledChanged(EventArgs) Inherited from ListControl
OnValueMemberChanged(EventArgs) Inherited from ListControl
SelectedValue Inherited from ListControl
SelectedValueChanged Inherited from ListControl

Events

Click

Occurs when the user clicks the CheckedListBox control.

DataSourceChanged

Occurs when the DataSource property changes.

DisplayMemberChanged

Occurs when the DisplayMember property changes.

DrawItem

Occurs when a visual aspect of an owner-drawn CheckedListBox changes. This event is not relevant to this class.

ItemCheck

Occurs when the checked state of an item changes.

MeasureItem

Occurs when an owner-drawn ListBox is created and the sizes of the list items are determined. This event is not relevant to this class.

MouseClick

Occurs when the user clicks the CheckedListBox control with the mouse.

ValueMemberChanged

Occurs when the ValueMember property changes.

Applies to

See Also