DataGridViewHeaderCell::GetInheritedContextMenuStrip Method (Int32)
.NET Framework (current version)
Gets the shortcut menu of the header cell.
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
Parameters
- rowIndex
-
Type:
System::Int32
Ignored by this implementation.
Return Value
Type: System.Windows.Forms::ContextMenuStrip^A ContextMenuStrip if the DataGridViewHeaderCell or DataGridView has a shortcut menu assigned; otherwise, null.
If the DataGridViewHeaderCell does not have a shortcut menu, the DataGridViewHeaderCell will inherit the shortcut menu from the DataGridView. If the DataGridView also does not have a shortcut menu, then the GetInheritedContextMenuStrip method will return null.
.NET Framework
Available since 2.0
Available since 2.0
Show: