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.
Hello!
I´m using a 1.6 version of the Grid and I want to clone a DataBoundGrid object, but there´s no Clone() method available (Or maybe i can´t find it).
Is there any method with the same functionality?
Thanks in advance.
ADAdministrator Syncfusion Team November 19, 2004 08:53 AM UTC
There is no clone method for a GridDataBoundGrid.
As far as the data the grid displays, you would either use the same datasource or clone the datasource and use it.
There is a Clone method for the grid.GridBoundColumns object (or grid.Binder.InternalColumns if you did not add GridBounds). So you can use that to get a clone of the column information. Here is a thread that uses this clone in persisting column order and widths to a disk file. You could use something similar to create your own clone of these properties.
http://www.syncfusion.com/Support/Forums/message.aspx?MessageID=3918
ADAdministrator Syncfusion Team November 19, 2004 11:03 AM UTC
We try to use this method but when we refill de datasource before clone the grid.GridBoundColumns the control don´t refresh any changes.
We have to print a datasource keeping the column format, but we can´t reload the datasource in the control. So we need to make a clone, in memory, of the grid model, load the new datasource and print it.
Thanks in advance.
Rafael Gomez Hernando
>There is no clone method for a GridDataBoundGrid.
>
>As far as the data the grid displays, you would either use the same datasource or clone the datasource and use it.
>
>There is a Clone method for the grid.GridBoundColumns object (or grid.Binder.InternalColumns if you did not add GridBounds). So you can use that to get a clone of the column information. Here is a thread that uses this clone in persisting column order and widths to a disk file. You could use something similar to create your own clone of these properties.
>http://www.syncfusion.com/Support/Forums/message.aspx?MessageID=3918
ADAdministrator Syncfusion Team November 19, 2004 12:30 PM UTC
Here is a little sample showing how you might clone a GridDataBoundGrid in memory. (There may be other properties that you want to handle as well.)
CloneGridDataBoundGrid_8898.zip