Export (0) Print
Expand All
Expand Minimize

DataGridView.AccessibilityNotifyCurrentCellChanged Method

Notifies the accessible client applications when a new cell becomes the current cell.

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

protected virtual void AccessibilityNotifyCurrentCellChanged(
	Point cellAddress
)

Parameters

cellAddress
Type: System.Drawing.Point
A Point indicating the row and column indexes of the new current cell.

ExceptionCondition
ArgumentOutOfRangeException

The value of the X property of cellAddress is less than 0 or greater than the number of columns in the control minus 1.

-or-

The value of the Y property of cellAddress is less than 0 or greater than the number of rows in the control minus 1.

This method converts the specified row and column indexes into objectID and childID parameters and calls the AccessibilityNotifyClients(AccessibleEvents, Int32, Int32) method overload twice using the Focus and Selection values of the AccessibleEvents enumeration. The objectID and childID are determined by numbering only the visible rows and columns in their display order, counting the row or column headers if they are visible, and starting with 1. For example, if column headers are visible, the objectID for the first visible nonheader row is 2.

Notes to Inheritors

Override this method when customizing the DataGridView control and modifying how and when the current cell changes. For example, if you create a custom row type that merges multiple cells into single cells and you modify the navigation accordingly, you can override this method to provide accessibility support for your changes.

.NET Framework

Supported in: 4, 3.5, 3.0, 2.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Community Additions

ADD
Show:
© 2014 Microsoft