Author: Kruddler | Posted on: 4/6/2009 10:28:34 PM | Views : 481

I have an ASCX control. Inside the control is many other controls which all have names. The problem is that I want to have multiple instances of the control on one page. But, the second control that renders is incorrectly because the names of the controls inside the ASCX already exist on the page. I don't know how to work around this.

Here are some things I have tried already:

Attempt to being control name to control property:

 <cc1:Map runat="server" ID="<%# MapControlID %>">" Width="740" Height="432" Mode="Normal" OnClick="theMap_Click"></cc1:Map>

But I just get this error:

The ID property of a control can only be set using the ID attribute in the tag and a simple value. Example: <asp:Button runat="server" id="Button1" />
 

< ...

Go to the complete details ...