RowDblClick Direct Event Issue

  1. #1

    RowDblClick Direct Event Issue

    Hi,

    I am using a grid panel to dispaly list of records . I have applied RowDblClick event in grid panel for editing the record.. It works fine in IE 8.

    But doesn't works in any other browser Chrome , Firefox etc...
    <DirectEvents> <RowDblClick OnEvent="BtnEdit_Click"> </RowDblClick> </DirectEvents>
    Whether im doing any thing wrong...? or its an open issue ....?

    Pls Help......
    Last edited by Daniil; Apr 13, 2012 at 4:24 PM. Reason: Please use [CODE] tags
  2. #2
    Hi,

    Please ask any technical support questions related to Ext.NET v1 on the Help 1.x forum.

    Regarding the question.

    Please provide a sample to reproduce.
  3. #3
    Quote Originally Posted by Daniil View Post
    Hi,

    Please ask any technical support questions related to Ext.NET v1 on the Help 1.x forum.

    Regarding the question.

    Please provide a sample to reproduce.
    Hi Danill........

    Pls find the sample code .. there is no problem on getting values from db and displaying it.
    The issue is that i have applied a Rowdoubleclickevent inside grid panel ......
    <RowDblClick OnEvent="BtnEdit_Click">
                                    <ExtraParams>
                                        <ext:Parameter Name="Values" Value="Ext.encode(#{GrdCenPckList1}.getRowsValues({selectedOnly:true}))"
                                            Mode="Raw" />
                                    </ExtraParams>
                                </RowDblClick>
    Even the code works fine in IE ( RowDblclick Event Occurs) , It doesn't reproduce the same in other browsers .. Chrome,Firefox etc..

    <ext:GridPanel ID="GrdCenPckList1" runat="server" StoreID="StoreTest" StripeRows="true" AutoExpandColumn="Department" Region="Center" TrackMouseOver="true" Height="460" AutoScroll="true"> <DirectEvents> <RowDblClick OnEvent="BtnEdit_Click"> <ExtraParams> <ext:Parameter Name="Values" Value="Ext.encode(#{GrdCenPckList1}.getRowsValues({selectedOnly:true}))" Mode="Raw" /> </ExtraParams> </RowDblClick> </DirectEvents> <ColumnModel ID="ColumnModel1" runat="server"> <Columns> <ext:RowNumbererColumn /> <ext:Column ColumnID="Department" Header="Department" Width="160" DataIndex="Department" /> <ext:Column ColumnID="CREATEDBY" Header="Created By" Width="160" DataIndex="Created_By" /> <ext:DateColumn ColumnID="CREATEDDATE" Header="Created Date" Width="160" DataIndex="Created_Date" Format="dd/MM/yyyy" /> </Columns> </ColumnModel> <SelectionModel> <ext:CheckboxSelectionModel ID="CheckboxSelectionModel1" runat="server" /> </SelectionModel> <KeyMap> <ext:KeyBinding> <Keys> <ext:Key Code="DELETE" /> </Keys> <Listeners> <Event Handler="deleteRows(#{GrdCenPckList1});" /> </Listeners> </ext:KeyBinding> </KeyMap> <BottomBar> <ext:PagingToolbar ID="PgrCenPckList1" runat="server" PageSize="20" StoreID="StoreTest" HideRefresh="true" /> </BottomBar> </ext:GridPanel> <ext:Store ID="StoreTest" runat="server"> <Reader> <ext:JsonReader IDProperty="ID"> <Fields> <ext:RecordField Name="Department" /> <ext:RecordField Name="Created_By" /> <ext:RecordField Name="Created_Date" Type="Date" /> </Fields> </ext:JsonReader> </Reader> </ext:Store> //////////////////// C # Code /////////////////// protected void BtnEdit_Click(object sender, DirectEventArgs e) { RowSelectionModel sm = this.GrdCenPckList1.SelectionModel.Primary as RowSelectionModel; if (sm.SelectedRows.Count == 0) X.Msg.Alert("Edit Row", "Select a row to edit").Show(); else if (sm.SelectedRows.Count > 1) { X.Msg.Alert("Edit Row", "Only one row can be edited at a time").Show(); sm.ClearSelections(); } else { X.Msg.Alert("Edit Row", "One row is ready to edit").Show(); sm.ClearSelections(); } }
    Last edited by Daniil; Apr 28, 2012 at 6:45 AM. Reason: Please use [CODE] tags for all code
  4. #4
    Apologize for the delay.

    What is the behavior in non IE browsers? Is there any error?

    Generally, I can't see any reason why it works in IE only on your side. As well, I am unable to reproduce it.

    Please provide a full example and exact steps to reproduce the problem.

    Regarding the example.

    Please place code behind into
    <script runat="server">
        //code behind
    </script>
    directly on a page.

    It would be a great help for us.

    So, you example can look the following way that allows us to just copy, paste and run.

    Example
    <%@ Page Language="C#" %>
    
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    
    <%@ Import Namespace="System.Data" %>
    
    <script runat="server">
        protected void Page_Load(object sender, EventArgs e)
        {
    
        }
    </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>
    </head>
    <body>
        <%--MARKUP--%>
    </body>
    </html>
  5. #5
    Quote Originally Posted by Daniil View Post
    Apologize for the delay.

    What is the behavior in non IE browsers? Is there any error?

    Generally, I can't see any reason why it works in IE only on your side. As well, I am unable to reproduce it.

    Please provide a full example and exact steps to reproduce the problem.

    Regarding the example.

    Please place code behind into
    <script runat="server">
        //code behind
    </script>
    directly on a page.

    It would be a great help for us.

    So, you example can look the following way that allows us to just copy, paste and run.

    Example
    <%@ Page Language="C#" %>
    
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    
    <%@ Import Namespace="System.Data" %>
    
    <script runat="server">
        protected void Page_Load(object sender, EventArgs e)
        {
    
        }
    </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>
    </head>
    <body>
        <%--MARKUP--%>
    </body>
    </html>
    Hi Danill...

    Thanks for looking over this...

    The problem is that i need two options
    1.) check box selection for selecting multiple rows in a Grid ( Delete )
    2.) Row Double click selection for editing the record..

    <SelectionModel>                      
                                <ext:RowSelectionModel ID="RowSelectionModel" runat="server" />
                                <ext:CheckboxSelectionModel ID ="CheckboxSelectionModel1" runat ="server" />
                            </SelectionModel>
    Similar to the one what we have in gmail, yahoo etc.........

    But when i use Ext Grid ... either one is possible for me.. is it possible to overcome this ...

    Pls Help...
  6. #6
    Yes, only one selection model is supported at the moment.

    1.) check box selection for selecting multiple rows in a Grid ( Delete )
    I think you should use the CheckboxSelectionModel with
    CheckOnly="true"
    2.) Row Double click selection for editing the record..
    I'm not sure what should happen on double click. Please clarify.

Similar Threads

  1. [CLOSED] Dynamic header column component direct event Issue
    By legaldiscovery in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Dec 21, 2015, 10:56 PM
  2. [CLOSED] Output Cache issue with Direct Method / Direct Event
    By amitpareek in forum 1.x Legacy Premium Help
    Replies: 18
    Last Post: Mar 01, 2013, 5:03 AM
  3. [CLOSED] Button Issue Direct Event (IE6-IE7-IE8)
    By nhg_itd in forum 1.x Legacy Premium Help
    Replies: 6
    Last Post: Nov 10, 2011, 6:23 AM
  4. Replies: 7
    Last Post: Jun 28, 2011, 11:13 AM
  5. [CLOSED] [1.0] Issue with success property on direct event of textfield
    By bryantharpe in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: May 07, 2010, 5:06 PM

Tags for this Thread

Posting Permissions