CommandColumn and DirectEvents

  1. #1

    CommandColumn and DirectEvents

    How to using CommandColumn and DirectEvents??
  2. #2

    Welcome to our forum!

    Please, take a look at the following example:

    <%@ Page Language="C#" %>
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    <!DOCTYPE html>
    <head runat="server">
        <script runat="server">
            protected void GridCommand(object sender, DirectEventArgs e)
                X.Msg.Alert("Command", "Command have been pressed").Show();
        <form runat="server">
            <ext:ResourceManager runat="server" />
                Title="My Task List"
                            <ext:Node Text="To Do" Icon="Folder" Expanded="true">
                                    <ext:Node Text="Go jogging" Leaf="true" />
                                    <ext:Node Text="Take a nap" Leaf="true" />
                                    <ext:Node Text="Clean house" Leaf="true" />
                            <ext:Node Text="Grocery List" Icon="Folder" Expanded="true">
                                    <ext:Node Text="Bananas" Leaf="true" />
                                    <ext:Node Text="Milk" Leaf="true" />
                                    <ext:Node Text="Cereal" Leaf="true" />
                                    <ext:Node Text="Energy foods" Icon="Folder" Expanded="true">
                                            <ext:Node Text="Coffee" Leaf="true" />
                                            <ext:Node Text="Red Bull" Leaf="true" />
                            <ext:Node Text="Kitchen Remodel" Icon="Folder" Expanded="true">
                                    <ext:Node Text="Finish the budget" Leaf="true" />
                                    <ext:Node Text="Call contractors" Leaf="true" />
                                    <ext:Node Text="Choose design" Leaf="true" />
                        <ext:TreeColumn runat="server" Flex="1" DataIndex="text" />
                        <ext:CommandColumn runat="server" Width="40">
                                <ext:GridCommand CommandName="Edit" Icon="PageWhiteEdit" ToolTip-Text="Edit task" />
                            <PrepareToolbar Handler="return;" />
                                <Command OnEvent="GridCommand"></Command>

Similar Threads

  1. [CLOSED] CommandColumn how to set Css??
    By gs_user in forum 2.x Legacy Premium Help
    Replies: 2
    Last Post: Nov 29, 2012, 4:22 AM
  2. [CLOSED] CommandColumn and DirectEvents
    By Stefanaccio in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Aug 26, 2010, 9:45 AM
  3. CommandColumn in codebehind
    By roszman in forum 1.x Help
    Replies: 0
    Last Post: Apr 28, 2010, 9:42 AM
  4. Help. regarding commandcolumn
    By ydnah2 in forum 1.x Help
    Replies: 2
    Last Post: Aug 19, 2009, 11:46 AM
  5. CommandColumn
    By Rod in forum Feature Requests
    Replies: 7
    Last Post: Oct 27, 2008, 2:17 PM

Tags for this Thread

Posting Permissions