Populate rich txt data into Cuteeditor with all the formatting

Last post 05-18-2010, 4:37 AM by Kenneth. 1 replies.
Sort Posts: Previous Next
  •  05-18-2010, 12:27 AM 61076

    Populate rich txt data into Cuteeditor with all the formatting

    Hi,
     
    Using vs2003 rich text box some data will be saved to database with text manipulations.Now, i am using vs 2005 web application,i want to populate that data saved from Richtextbox.As, there is not richtextbox in asp.net,i tried cuteeditor.But,when i tried to populate using text property or xhtml property i am not getting the data displayed with formatting.
     
    Do,i need to do any settings to the editor tag to display data with all the settings.
     
    Thanks,
    Adi.
  •  05-18-2010, 4:37 AM 61092 in reply to 61076

    Re: Populate rich txt data into Cuteeditor with all the formatting

    Hi adityaraj,
     
    Please try the example below
     
    1. <%@ Page Language="C#" ValidateRequest="false" %>   
    2.   
    3. <%@ Register TagPrefix="CE" Namespace="CuteEditor" Assembly="CuteEditor" %>   
    4.   
    5. <script runat="server">   
    6.   
    7.     protected void button1_Click(object sender, EventArgs e)   
    8.     {   
    9.         label1.Text ="you type:"+ editor1.Text;   
    10.     }   
    11. </script>   
    12.   
    13. <html>   
    14. <head>   
    15. </head>   
    16. <body>   
    17.     <form id="Form1" runat="server">   
    18.         <CE:Editor ID="editor1" runat="server" Height="500">   
    19.         </CE:Editor>   
    20.         <asp:Label ID="label1" runat="server"></asp:Label>   
    21.         <asp:Button ID="button1" runat="server" Text="get editor text" OnClick="button1_Click" />   
    22.         
    23.     </form>   
    24. </body>   
    25. </html>  
    Regards,
     
    Ken
View as RSS news feed in XML