Unable To set row visible false of a datagridview

After searching a lot, I got the solution

CurrencyManager currencyManager1 = (CurrencyManager)BindingContext[MyGrid.DataSource];  
currencyManager1.SuspendBinding();
MyGrid.Rows[5].Visible = false;
currencyManager1.ResumeBinding();

Leave a Comment