[CLOSED] TinyMCE

  1. #1

    [CLOSED] TinyMCE

    Anyone get TinyMCE to work as a UX control to Ext.NET?

    Cheers
    Last edited by Daniil; Mar 22, 2011 at 10:14 AM. Reason: [CLOSED]
  2. #2
    Hi,

    You can use ExtJS ready extensions, like this
    http://blogs.byte-force.com/xor/tinymce/index.html
    Vladimir Shcheglov
    Sr. Developer
  3. #3
    Quote Originally Posted by Vladimir View Post
    Hi,

    You can use ExtJS ready extensions, like this
    http://blogs.byte-force.com/xor/tinymce/index.html
    Thanks vladsch,

    How would you go around rendering the control in a mixture of the Ext controls? I have a form panel and would want it to render in a particular place.

    Cheers
  4. #4
    Hi,

    You can use GenericComponent class
    Here is the sample how to use it

    ExtJs widget
    Ext.net.AcceptDecline = Ext.extend(Ext.Toolbar, {
        flat : true,
        cls : "x-inline-toolbar",    
        
        initComponent : function(){        
            
            this.items = [
                {
                    xtype: "button",
                    text: "Accept",
                    ref: "acceptBtn",
                    enableToggle : true,
                    toggleGroup: this.id + "_choice"
                },
                {
                    xtype: "button",
                    text: "Decline",
                    ref : "declineBtn",
                    enableToggle : true,
                    toggleGroup: this.id + "_choice"
                }
            ];
            
            Ext.net.AcceptDecline.superclass.initComponent.call(this);        
        }
    });
    Ext.reg('acceptdecline', Ext.net.AcceptDecline);
    Aspx page
    <%@ Page Language="C#" %>
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    
    <script runat="server">
        protected void Page_Load(object sender, EventArgs e)
        {
            Panel1.Items.Add(new GenericComponent<Toolbar>
            {
                GenericXType = "acceptdecline",
                GenericInstanceOf = "Ext.net.AcceptDecline",
                Component = { 
                    FieldLabel = "Question 1 "
                }
            });
    
            Panel1.Items.Add(new GenericComponent<Toolbar>
            {
                GenericXType = "acceptdecline",
                GenericInstanceOf = "Ext.net.AcceptDecline",
                Component =
                {
                    FieldLabel = "Question 2 "
                }
            });
    
            Panel1.Items.Add(new GenericComponent<Toolbar>
            {
                GenericXType = "acceptdecline",
                GenericInstanceOf = "Ext.net.AcceptDecline",
                Component =
                {
                    FieldLabel = "Question 3 "
                }
            });
        }
    </script>
    
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
        <title>Ext.NET Example</title>
        
        <ext:ResourcePlaceHolder runat="server" Mode="ScriptFiles" />
        <script src="Ext.net.AcceptDecline.js" type="text/javascript"></script>
    </head>
    <body>
        <form runat="server">
            <ext:ResourceManager runat="server" />
            
            <ext:Panel ID="Panel1" runat="server" Title="Questions" AutoHeight="true">            
            </ext:Panel>   
        </form>
    </body>
    </html>
    In your case generic type can be TextArea or TextField
    Vladimir Shcheglov
    Sr. Developer

Similar Threads

  1. TINYMCE HTML Editor in tab panel
    By CoolNoob in forum 1.x Help
    Replies: 0
    Last Post: Nov 13, 2009, 7:24 AM

Tags for this Thread

Posting Permissions