Re: Javascript API Document?

  •  11-04-2010, 3:30 AM

    Re: Javascript API Document?

    Hi SKH,
     
    If you mean that, achieve the same function as the toolbar buttons by javascript.Please try the code below 
    1. <%@ Page Language="C#" AutoEventWireup="true" %>  
    2.   
    3. <%@ Register TagPrefix="CE" Namespace="CuteEditor" Assembly="CuteEditor" %>  
    4. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">  
    5. <html xmlns="http://www.w3.org/1999/xhtml">  
    6. <head id="Head1" runat="server">  
    7.     <title></title>  
    8. </head>  
    9. <body>  
    10.     <form id="form1" runat="server">  
    11.         <CE:Editor ID="editor1" runat="server">  
    12.         </CE:Editor>  
    13.         <input type=button value="Open image dialog" onclick="openImageDialog()" />  
    14.     </form>  
    15. </body>  
    16. </html>  
    17.   
    18. <script type="text/javascript">  
    19. function openImageDialog()  
    20. {  
    21.     var editor1=document.getElementById("<%= editor1.ClientID %>");  
    22.     //InsertImage is the command name which use for open the image dialog  
    23.     editor1.ExecCommand("InsertImage");  
    24. }  
    25. </script>  
    You can find all commands name in "http://www.cutesoft.net/developer+guide/scr/Toolbar_Customization.htm"
     
    -->Section  "Toolbar Configuration Reference:"--> "Template Item" column
     
    Regards,
     
    ken 
View Complete Thread