Undo Event

Last post 05-13-2010, 9:39 PM by Kenneth. 1 replies.
Sort Posts: Previous Next
  •  05-13-2010, 1:29 PM 60995

    Undo Event

    Can I detect an Undo event (like CuteEditor_OnCommand() )
     
    I need to display changed text when an Undo operation is called. I tried following and it did not work:
     
     function CuteEditor_OnUndo(editor)
     { //when the content be changed.
    document.getElementById("Results1").innerHTML = editor.getHTML();
    }
     
    Thank you,
    Piyush

    Piyush Varma
  •  05-13-2010, 9:39 PM 61006 in reply to 60995

    Re: Undo Event

    hi piyushvarma,
     
    Please try
     
    1. <%@ Page Language="C#" ValidateRequest="false" Debug="true" %>   
    2.   
    3. <%@ Register TagPrefix="CE" Namespace="CuteEditor" Assembly="CuteEditor" %>   
    4. <html>   
    5. <head>   
    6. </head>   
    7. <body>   
    8.     <form id="Form1" runat="server">   
    9.         <CE:Editor ID="editor1" runat="server"  CustomCulture=en-us>   
    10.         </CE:Editor>   
    11.     </form>   
    12. </body>   
    13. </html>   
    14. <script>   
    15. function CuteEditor_OnCommand(editor,command,ui,value)   
    16. {   
    17. if(command=="Undo")   
    18. {   
    19. alert("you click undo button");   
    20. }   
    21. }   
    22. </script>  
    Regards,
     
    ken
View as RSS news feed in XML