开发者

creating RadEditor dynamically asp.net

开发者 https://www.devze.com 2023-03-25 22:58 出处:网络
I want to add RadEditor dynamically. It is getting added to the page but as s开发者_开发技巧oon as postback occurs i get Multiple controls with the same ID \'EditorRibbonBarResourcesHolder\' were foun

I want to add RadEditor dynamically. It is getting added to the page but as s开发者_开发技巧oon as postback occurs i get Multiple controls with the same ID 'EditorRibbonBarResourcesHolder' were found. Below is the code that i am using to add control dynamically.

RadEditor editor = new RadEditor();
editor.ID = "editor_" + itemTypeattribute.ItemAttributeID + rand.Next();
cellAttributeValue.Controls.Add(editor);
editor.DialogOpener.ID = "editor_dialopOpener_" + itemTypeattribute.ItemAttributeID;
editor.DialogOpener.Window.ID = "editor_dialopOpener_window_"+ ItemTypeattribute.ItemAttributeID;
editor.ClientIDMode = ClientIDMode.AutoID;
editor.EnableEmbeddedScripts = true;
editor.Height = 200;

Any help is appreciated. Thanks


Whenever I need to use a radeditor "dynamically" I have it on the page from the start with visible=false and then show it when I need it.

0

精彩评论

暂无评论...
验证码 换一张
取 消