如何隐藏在datagridview的行从一行指数2和至死不渝开始?

时间:2019-02-02 15:59:13

标签: c# winforms

private void HideRows(object sender, DataGridViewCellEventArgs e)
{
    IndexRows = RowIndex;

    if (IndexRows>2)
    {
        DataGridView.Rows[IndexRows].Visible=false;
    }
    else
    {
        DataGridView.Rows[IndexRows].Visible=true;
    }
}

1 个答案:

答案 0 :(得分:1)

core