It appears there is some kind of issue with calling ClearDataSource on a postback and the presence of the "Multiple controls with the same ID error" being thrown when a Template control exists in the WebDataGrid.
I have a template column with a checkbox and if I use the ClearDataSource call before rebinding the WebDataGrid on a postback I get the "Multiple controls..." error presumably related to the checkbox. If I comment out the ClearDataSource my postback works just fine and I don't get the fatal error but then, even though I'm rebinding the WebDataGrid (with a refreshed object List<T> collection pulled from the db) on the postback, the OnInitializeRow event handler does not fire again - it will fire on the intiial page load and that's it - which also is a problem as I set some custom cell tooltips when the InitializeRow event is fired - seem's I'm darned if I do, and darned if I don't. Anyone have any thoughts.
Hello majensen,
There was a very similar development issue. Would you test your project with the latest service release for your version, and check whether this error still happens.
Regards,
Lyuba
Developer Support Engineer
Infragistics
www.infragistics.com/support
I am facing the same issue. has this been fixed in a later release?
It is not fixed as of 2010.3 SR 2056 - I am trying to work with Infragistics to get it resolved - I provided an example solution to them.
I've got this same error as well. This has been fixed in the past for us back in 2009.2 I think.
Managed to find a workaround. Add
"grid.Rows.Clear();"
Before calling ClearDataSource.
Tried the workaround - regretfully it does not work for me - get the same error regarding duplicate control id's - this is in 10.3.20103.2056.
Hi,
It is strange in my case.
When on local development machine, I try to open the page it gives me same id error.
Then I access the development server from a remote machine, the page opens with no problem.
Then I open locally and now it opens...
I tried grid.rows.clear() it worked now, but I do not know it is beacuse I first logged from a remote
machine or not... (my version is 10.V3.2120)
Cheers
I have the same problem with WebDataGrid Version=10.3.20103.2073, and the DataBind code below
private void BindData()
{ this.WebDataGrid1.Rows.Clear(); this.WebDataGrid1.ClearDataSource(); this.WebDataGrid1.DataSource = this.ods_DataPointValueSet.Select(); this.WebDataGrid1.DataBind(); //this.WebDataGrid1.DataSourceID = "ods_DataPointValueSet"; //.DataSource = this.ods_DataPointValueSet.Select(); }
The workaround is also not working for me. Getting the same error with 10.3.20103.2073