I'm having troubles with dynamically adding some attributes to IMG tag within the asp:Panel.
Here is the code:
<asp:Panel ID="panelArea" runat="server">
<table border="0" width="100%">
<asp:PlaceHolder ID="phArea" runat="server" />
<img id='<%= "tabImg" + ClientID %>' src='<%= ImageUrlOpen %>' />
The error I keep getting is The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).
Has anyone faced this problem earlier?