This is a migrated thread and some comments may be shown as answers.

RadEditor losing content in IE11 in asp.net.

4 Answers 32 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Sampath
Top achievements
Rank 1
Sampath asked on 15 Oct 2018, 12:26 PM

<telerik:RadEditor ID="txtWarning" runat="server" EditModes="Design" ToolbarMode="Default" Width="400px" Height="100px" MaxTextLength="1000" ContentAreaMode="Div" ContentFilters="None" ></telerik:RadEditor>

 

string text = txtWarning.Content

4 Answers, 1 is accepted

Sort by
0
Rumen
Telerik team
answered on 15 Oct 2018, 01:50 PM
Hi there,

Have you tried the proposed solutions at RadEditor Content Not Saved After Ajax Update in Firefox, Google Chrome and Safari

The issue could be also related to overriding the editor content in your Page_Load method. Please note that if you read the content of the editor in an event handler (such as a button event handler) this event handler executes later in the page lifecycle compared to Page_Load. This is why, in case you set the initial content in Page_Load it is mandatory to add a !Page.IsPostBack check, e.g.

if (!Page.IsPostBack)
{
    RadEditor1.Content = "Some content";
}



Regards,
Rumen
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
0
Sampath
Top achievements
Rank 1
answered on 17 Oct 2018, 10:53 AM

hi Rumen, 

thank you for your reply, you made my day.

but RadEditor not losing data if i use UseSubmitBehavior="false" for button, if not RadEditor losing data in save_click event.

and if i keep UseSubmitBehavior="false", then am unable to use onClientClick event for button.

<asp:Button CssClass="button" ID="btnSave" runat="server" UseSubmitBehavior="false" Text="Save" OnClick="btnSave_Click" meta:resourcekey="btnSaveResource1" />

Please given me a solution to use onClientClick and onClick for the button. i need client event and server event for button. because iam doing validations in onClientclick.

 <asp:Button CssClass="button" ID="btnSave" runat="server"  Text="Save" OnClick="btnSave_Click" meta:resourcekey="btnSaveResource1"  onClientClick = "ComparePassword()" />

 

0
Accepted
Rumen
Telerik team
answered on 17 Oct 2018, 12:32 PM
Hi Sampath,

The following StackOverflow marked as answer post discusses the issue you are facing:

This article kind of explains the problem. You need to return true in your JS if you want the server event to trigger. Otherwise, you have to return false.

And, it also looks like you will have to add the UseSubmitBehavior = false based on: OnclientClick and OnClick is not working at the same time?

This is especially evident after seeing that your generated HTML only has the CloseDialog() and not the call to Button1_Click. This change will concatenate to the end of your onclick.

<asp:Button ID="Button1" runat="server" Text="Soumettre ce ticket" onclick="Button1_Click" OnClientClick="CloseDialog();" UseSubmitBehavior="false"/>


Regards,
Rumen
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
0
Sampath
Top achievements
Rank 1
answered on 17 Oct 2018, 12:40 PM
Thanks a lot Rumen.
Tags
Editor
Asked by
Sampath
Top achievements
Rank 1
Answers by
Rumen
Telerik team
Sampath
Top achievements
Rank 1
Share this question
or