AI OnAI Off
function addEmailPopupButton(strNameOfEmailField)
{
if (document.getElementById)
{
var objPopupButton = " ";
var objEmailTextField = document.getElementById(strNameOfEmailField);
objEmailTextField.parentElement.innerHTML = objEmailTextField.parentElement.innerHTML + objPopupButton;
}
}
The reason for the error is because the dynamically added usercontrol for email links has code like this:
]]>>
(see Util\LinkGenericMail.ascx)
Using ODA is not easy when controls are added dynamically. The shadowfiles can only be used if the file does not load a user control dynamically, like in this example.
Maybe the developers at EP should change that ;)
TextBox urlControl = (TextBox)control.FindControl("linkUrl");
which is fine. Now I would like to add a HtmlButton next to it, by usingcontrol.Controls.Add( new HtmlButton() );
where "control" is the Control that holds the inputcontrols for the linkspace placeholder. I get the runtime error : The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>). Any workarounds for this? %>