Free Support Forum - aspose.com

Using a Grid in a UserControl

I'm using VS2005, ASP.NET and .NET 2.0. I've created a UserControl and dropped a Grid on that control with the designer. Sometimes it works but other times I get the following error ..

Multiple controls with the same ID '_ctl0:OptInHistoryList1:GR01:CC' were found. Trace requires that controls have unique IDs.

I've tried the suggestions in other threads about using the INamingContainer, but that doesn't seem to make it anymore reliable. The usercontrol that has the grid is dynamically added to the page using ...

_content.Controls.Add(c);

Seems to always die after the first couple runs, aftwards it loads ok. Ideas?

Hi,

We will get back to you soon for your issue.

Thank you.

Hi,

I have test the control in a UserControl and everything seems to be ok. So could you create a project which shows the problem and post it here?