RadEditor looses contet

2 posts, 0 answers
  1. Kalyani
    Kalyani avatar
    20 posts
    Member since:
    Jul 2011

    Posted 30 May 2013 Link to this post

    Hello,

    I have a radwindow inside which I have a radeditor.  I load the radeditor with content from a database.  I have a preview button in the radwindow and when I click that it opens another radwindow.  When I close this radwindow it deletes the content in the radeditor.  It does not affect the rest of the controls in the radwindow.  It just affects the radeditor.  How do I fix this.

    Here is my code with both the radwindow- 

    <tlrk:RadWindow ID="Dialog1" runat="server" Width="900px" VisibleStatusbar="false" Behaviors="Close,Move">
      <ContentTemplate>
       <asp:UpdatePanel ID="Dialog1UpdatePanel" runat="server" UpdateMode="Conditional">
        <ContentTemplate>
         <div class="DialogBase DialogShading1" style="width:100%">
          <br />
          <asp:Label ID="lblSql" runat="server" Text =""/>
          <table class="center" style="width: 100%;">
           <tr>
            <td align="left" style="padding:10px"><strong>Help ID</strong> <br />
             <asp:TextBox ID="D0_txtHelpID" runat="server" Width="300px"  /></td>
            <td align="left"><strong>Title</strong> <br />
             <asp:TextBox ID="D0_txtTitle" runat="server" Width="500px"  /></td>
           </tr>
           <tr valign="top">
            <td align="left" style="padding:10px"><strong>Module</strong> <br />
             <asp:TextBox ID="D0_txtModule" runat="server" Width="300px"  /><br /><br />
             <strong>Page</strong><br />
             <asp:TextBox ID="D0_txtPage" runat="server" Width="300px"  /><br /><br />
             <strong>Dialog</strong><br />
             <asp:TextBox ID="D0_txtDialog" runat="server" Width="300px" /><br /><br />
             <strong>Item</strong><br />
             <asp:TextBox ID="D0_txtItem" runat="server" Width="300px" /> <br /><br />
             <strong>Note</strong><br /> 
             <asp:TextBox ID="D0_txtNote" runat="server" Width="300px" TextMode="MultiLine" Height="100px" />
            </td>
            <td align="left"><strong>Article</strong> <br />
             <tlrk:RadEditor ID="D0_RadArticle" runat ="server" Width="530px"  /> 
            </td>
           </tr>       
          </table>
          <div class="DialogFooter"> 
          <table border="0" cellspacing="0" cellpadding="0" width="100%">
            <tr>
             <td align="left" style="width: 500px">
              <asp:Button ID="D0_Preview" runat="server" Text="Preview"  CssClass="DialogButton" OnClientClick="Preview_Click();return false;" />
             </td>
             <td align="right">
              <asp:Button ID="D0_OK" runat="server" Text="Save" OnClick="D0_OK_Click" CssClass="DialogButton"/>
              <input type="submit" value="Cancel" onclick="OI.Dialog.CloseDialog('<%= Dialog1.ClientID %>');return false;" class="DialogButton" />
             </td>
            </tr>
           </table>
          </div>     
         </div>
        </ContentTemplate>
       </asp:UpdatePanel>
      </ContentTemplate> 
     </tlrk:RadWindow> 

      <%-- Help --%>
      <tlrk:RadWindow ID="HelpDialog" runat="server" Width="416px" Height="508px" VisibleStatusbar="false" Behaviors="Close,Move" Title="Help" 
       IconUrl="../Images/Ribbon/Buttons/help_16_normal.gif">
        <ContentTemplate>
         <div class="HelpDialogContent">
          <div class="DialogToolbar">
           <div class="HelpBackForwardOffset">
            <oi:RibbonButton ID="HelpBack" runat="server" ButtonType="Back22" OnClientClick="OI.Help.Back();return false;" FloatDirection="Left" ButtonSpacing="1" Enabled="false" Style="position:relative;" />
            <oi:RibbonButton ID="HelpForward" runat="server" ButtonType="Forward22" OnClientClick="OI.Help.Forward();return false;" FloatDirection="Left" ButtonSpacing="1" Enabled="false" Style="position:relative;" />
            <img alt="" id="HelpThrobber" src="../Images/Utility/throbber_blue.gif" style="float: right; padding-right: 3px; padding-top: 1px;" />
           </div>
          </div>
          <div id="HelpTitle">&nbsp;</div>
          <div id="HelpScroll" class="scrollVertical_386">
           <div id="HelpArticle" style="padding:10px;">
          <div style="height:170px;"></div>
          <div style="vertical-align:middle;text-align:center;">Loading... <img alt="" src="../Images/Utility/spinner_aero_16.gif" /></div>
         </div>
        </div>
         </div>
        </ContentTemplate>
       </tlrk:RadWindow>
  2. Misho
    Admin
    Misho avatar
    184 posts

    Posted 04 Jun 2013 Link to this post

    Hello,

    I tried to reproduce the unwanted behavior on my end, but no avail.
    I wasn't able to run your project due to various dependencies missing in it such as the database you are using. What I could advise you at this point is to to review the following demo showing a configuration similar to yours. If the provided information doesn't help you please try to isolate the issue in a simple, fully runnable project so that we will be able to reproduce and examine it locally.

    Regards,
    Misho
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Back to Top