System.Windows.Forms.DrawListViewItemEventArgs.DrawFocusRectangle Method

Draws a focus rectangle for the System.Windows.Forms.ListViewItem if it has focus.

Syntax

public void DrawFocusRectangle ()

Remarks

Use this method to draw a standard focus rectangle around the item. The focus rectangle is normally drawn within the area specified by the DrawListViewItemEventArgs.Bounds property. If the control is in the details view and the ListView.FullRowSelect property value is false, however, the focus rectangle is drawn around the default text area for the first column of the item.

The focus rectangle is drawn only when the item has focus, so you do not need to check the focus state of the item before you call this method.

Requirements

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