A
ata
Hi,
I need to create a PopupControlExtender dynamically, and attach it to
a LinkButton. i.e., when the LinkButton is clicked, I would like to
display a given literal control to the user. So, I tried the following
code:
LinkButton link = new LinkButton();
link.ID = "imgOtherAttributes" + caid;
link.CausesValidation = false;
link.Text = "other options";
LiteralControl lit2 = new LiteralControl();
lit2.ID = "popupWnd" + caid;
lit2.Text = "<div style='display:none;width:200px;height:
200px;background-color:red;'>test</div>";
AjaxControlToolkit.PopupControlExtender popup = new
AjaxControlToolkit.PopupControlExtender();
popup.ID = "popup" + caid;
popup.TargetControlID = link.ID;
popup.PopupControlID = lit2.ID;
popup.Position = AjaxControlToolkit.PopupControlPopupPosition.Right;
However, the LiteralControl isn't shown!
Any idea?
Thanks
Jack
I need to create a PopupControlExtender dynamically, and attach it to
a LinkButton. i.e., when the LinkButton is clicked, I would like to
display a given literal control to the user. So, I tried the following
code:
LinkButton link = new LinkButton();
link.ID = "imgOtherAttributes" + caid;
link.CausesValidation = false;
link.Text = "other options";
LiteralControl lit2 = new LiteralControl();
lit2.ID = "popupWnd" + caid;
lit2.Text = "<div style='display:none;width:200px;height:
200px;background-color:red;'>test</div>";
AjaxControlToolkit.PopupControlExtender popup = new
AjaxControlToolkit.PopupControlExtender();
popup.ID = "popup" + caid;
popup.TargetControlID = link.ID;
popup.PopupControlID = lit2.ID;
popup.Position = AjaxControlToolkit.PopupControlPopupPosition.Right;
However, the LiteralControl isn't shown!
Any idea?
Thanks
Jack