Quantcast
Channel: AjaxControlToolkit Work Item Rss Feed
Viewing all articles
Browse latest Browse all 4356

Commented Unassigned: Reset Value in asp:HtmlEditorExtender [28033]

$
0
0
I'm using the HtmlEditor from the Ajax Toolkit on a webform.

If a user clicks Cancel, all the fields on the form are reset to the previous value. Apart from the content in the HtmlEditor.

How can I achieve this?
Comments: The code for the editor is as follows (partial for readabiltiy): <asp:LinkButton ID="lnkDummy" runat="server"></asp:LinkButton> <asp:ModalPopupExtender ID="ModalPopupExtender1" BehaviorID="mpeHTMLEditorVoor" PopupControlID="pnlHTMLEditorVoor" TargetControlID="lnkDummy" runat="server"> </asp:ModalPopupExtender> <asp:Panel ID="pnlHTMLEditorVoor" CssClass="Popup" runat="server"> <asp:TextBox id="txtVoorlooptekst" style="width:100%;" Rows="20" TextMode="MultiLine" runat="server"></asp:TextBox> <asp:HtmlEditorExtender ID="htmlEditor1" TargetControlID="txtVoorlooptekst" runat="server"> asp:HtmlEditorExtender> <br /> <input type="button" id="cmdAnnulerenO" value="Annuleren" onclick="$find('mpeHTMLEditorVoor').hide();" /> &nbsp;&nbsp; <input type="button" id="cmdSluitenO" value="Sluiten" onclick="BewerkenTekst($('#txtVoorlooptekst').val(), 'divVoorlooptekst');" /> The Javascript on canceling is: document.forms['form1'].reset(); That clears the text in all the other textboxes, but not for the editor. I've tried to set the value of txtVoorlooptekst to "" and other simalar approaches, but with no result.

Viewing all articles
Browse latest Browse all 4356

Trending Articles



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