Quantcast
Channel: ASP.NET AJAX + Ajax Control Toolkit (ACT)
Viewing all articles
Browse latest Browse all 5678

Ajax HtmlEditorExtender not showing property in Updatepanel

$
0
0

Hi All,

I am using asp.net webforms (targetFramework="4.5.1") and I have just added ajaxcontroltoolkit 15.1 and this is working fine.

However, I am experiencing problems with the HtmlEditorExtender when inside my updatepanel which is not property showing: all buttons are grey without icons  and the textarea is just not visible.

I know this is a question that was asked thousands of times but I could only find a workaround in order to make the Ajax HtmlEditorExtender work and show properly when inside an updatepanel. The control doesn't load some of its resources when it is not set to render on the first pageLoad. In other words, if the control is in a second view of a MultiView control, or if it should Load somehow after a post back.

This is the code I am using:

<asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager><asp:TextBox ID="txtcontDescription" runat="server" CssClass="txtcontenttxtarea" TextMode="multiline" Columns="100" Rows="15"  Text='<%# Eval("ContinentDescription")%>'></asp:TextBox><cc1:HtmlEditorExtender ID="HtmlEditorfortxtcontDescriptionx" runat="server" ClientIDMode="Inherit" TargetControlID="txtcontDescription" EnableSanitization="false"><Toolbar><cc1:Undo/><cc1:Redo/><cc1:Bold/><cc1:Italic/><cc1:Underline/><cc1:InsertOrderedList/><cc1:InsertUnorderedList/><cc1:CreateLink/><cc1:UnLink/><cc1:RemoveFormat/><cc1:Cut/><cc1:Copy/><cc1:Paste/></Toolbar></cc1:HtmlEditorExtender>

The workaround is, as per http://ajaxcontroltoolkit.codeplex.com/workitem/27181, 

  1. Add a Panel control somewhere at the beginning of your page, out of the UpdatePanel.
  2. Add a TextBox with an HtmlEditorExtender in the Panel
  3. Set the Visible property of the Panel control to False

Do you have any other more elegant solution to this problem?

Thanks


Viewing all articles
Browse latest Browse all 5678

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>