The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
I have a grid displaying URLS and an ''Add New'' button
When i click the button a new row is added.
Now if i''m editing a row and i click the button, then the grid loses focus which means it saves the current row and then the New button adds a new entry.
I also have the ability to drag in a URL from internet explorer which calls the AddNew() method.
BUT since the focus is not lost on the grid then whatever changes you were making are lost.
So i tried this :
private void AcceptChanges(GridDataBoundGrid grid) {
// if we drag a URL in then the data doesnt get updates unless we do this
DataView dv = (DataView) grid.DataSource;
CurrencyManager cm = (CurrencyManager)this.BindingContext[dv];
cm.EndCurrentEdit();
}
I also tried
private void AcceptChanges(GridDataBoundGrid grid) {
// if we drag a URL in then the data doesnt get updates unless we do this
DataView dv = (DataView) grid.DataSource;
CurrencyManager cm = (CurrencyManager)this.BindingContext[dv];
((DataRowView) cm.Current).Row.AcceptChanges();
}
the currency manager correctly identifies the row i''m editing, but cm.EndCurrentEdit() does not save the data in the row.
How do i do this? There