StatusBarDrawItemEventHandler Delegate

 

Represents the method that will handle the DrawItem event of a StatusBar.

Namespace:   System.Windows.Forms
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)

type StatusBarDrawItemEventHandler = 
    delegate of 
        sender:Object *
        sbdevent:StatusBarDrawItemEventArgs -> unit

Parameters

sender
Type: System.Object

The source of the event.

sbdevent
Type: System.Windows.Forms.StatusBarDrawItemEventArgs

A StatusBarDrawItemEventArgs that contains the event data.

When you create a StatusBarDrawItemEventHandler delegate, you identify the method that will handle the event. To associate the event with your event handler, add an instance of the delegate to the event. The event handler is called whenever the event occurs, unless you remove the delegate. For more information about event handler delegates, see Handling and Raising Events.

The following code example demonstrates how to use the StatusBarPanel.Style property, the StatusBarDrawItemEventHandler delegate, the StatusBarDrawItemEventArgs class, the StatusBarPanelStyle enumeration and the Panel property. To run the example, paste the following code in a form. Call the InitializeStatusBarPanels method in the form's constructor or Load event-handling method.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 1.1
Return to top
Show: