DataGridViewCell.MouseMoveUnsharesRow(DataGridViewCellMouseEventArgs) 方法

定义

指示当鼠标指针移过行中某个单元格上时,该行是否取消共享状态。Indicates whether a row will be unshared when the mouse pointer moves over a cell in the row.

protected:
 virtual bool MouseMoveUnsharesRow(System::Windows::Forms::DataGridViewCellMouseEventArgs ^ e);
protected virtual bool MouseMoveUnsharesRow (System.Windows.Forms.DataGridViewCellMouseEventArgs e);
abstract member MouseMoveUnsharesRow : System.Windows.Forms.DataGridViewCellMouseEventArgs -> bool
override this.MouseMoveUnsharesRow : System.Windows.Forms.DataGridViewCellMouseEventArgs -> bool
Protected Overridable Function MouseMoveUnsharesRow (e As DataGridViewCellMouseEventArgs) As Boolean

参数

e
DataGridViewCellMouseEventArgs

包含事件数据的 DataGridViewCellMouseEventArgsA DataGridViewCellMouseEventArgs that contains the event data.

返回

Boolean

如果不共享该行,则为 true;否则为 falsetrue if the row will be unshared, otherwise, false. DataGridViewCell 基类总是返回 falseThe base DataGridViewCell class always returns false.

注解

MouseMoveUnsharesRow方法在方法之前调用 OnMouseMoveThe MouseMoveUnsharesRow method is called just before the OnMouseMove method. 在派生类中,如果对的 true 调用具有取消 OnMouseMove 共享包含该单元格的行的效果,则该方法必须返回。In derived classes, it must return true if the call to OnMouseMove has the effect of unsharing the row containing the cell. 否则,它应返回 falseOtherwise, it should return false.

有关行共享的详细信息,请参阅 缩放 Windows 窗体 DataGridView 控件的最佳做法For more information about row sharing, see Best Practices for Scaling the Windows Forms DataGridView Control.

适用于

另请参阅