This is a migrated thread and some comments may be shown as answers.

AddHandler for each cells on Server

3 Answers 18 Views
Grid
This is a migrated thread and some comments may be shown as answers.
pedrotti
Top achievements
Rank 1
pedrotti asked on 17 Apr 2013, 10:20 AM
Hello

I have a radgrid with 20 identical columns and approximately 100 columns

I resumed  the test " Grid - Customer with Edict Batch Server Update " which works very well,

The fuction $addHandler(cell, "dblclick", Function.createDelegate(cell, ShowColumnEditor)); for each cell take a lot of time



Furthermore I am obliged to pass on every cell  to initialize the combobox

     If TypeOf e.Item Is GridDataItem Then
            Dim dataBoundItem As GridDataItem = e.Item


            Dim dtCIntervention As New DataTable
            dtCIntervention = ViewState("cInterventions")

            Dim PeuID As Integer = e.Item.OwnerTableView.DataKeyValues(e.Item.ItemIndex)("PeuID")
            Dim numCol As Integer
            Dim dt As New DataTable
            dt = ViewState("Intervention")
            Dim ddl As New DropDownList

            For r As Int16 = 1 To 19
                ddl = CType(dataBoundItem.FindControl("ddlcInt" & r), DropDownList)
                ddl.DataTextField = "cIntID"
                ddl.DataValueField = "cIntID"
                ddl.DataSource = dtCIntervention
                ddl.DataBind()
            Next

Is it possible to add the handler at the same time ...

Thank you in advance for your answers

Anne

3 Answers, 1 is accepted

Sort by
0
Angel Petrov
Telerik team
answered on 22 Apr 2013, 06:49 AM
Hello Anne,

I am experiencing difficulties understanding the requirement. Do you want to add a handler for a combo box event? Please provide a detail explanation so we could give you a precise answer.

Regards,
Angel Petrov
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
pedrotti
Top achievements
Rank 1
answered on 25 Apr 2013, 09:51 AM
Hello Angel

I do the same that the telerik example ' Grid - Customer with Edict Batch Server Update'

  <telerik:GridTemplateColumn UniqueName="Annee2" HeaderText="" HeaderStyle-Width="50px">
                        <ItemTemplate>
                            <asp:Label ID="An2" runat="server"></asp:Label>
                            <asp:DropDownList ID="ddlcInt2" runat="server" Style="display: none">
                            </asp:DropDownList>
                        </ItemTemplate>
                    </telerik:GridTemplateColumn>

On double click I mask the label and show the combobox.
To do this, I have to add the event 'double click'  on every cell thas take a lot of time

Thank yopu for your help

Anne
0
Angel Petrov
Telerik team
answered on 30 Apr 2013, 06:42 AM
Hi Anne,

A performance issue may occur in a scenario with a grid that has a large number of rows and columns. Currently our developers are integrating the batch editing functionality in RadGrid and it will be available from the next official release. By using this new built-in functionality the performance issues should be resolved. For now you can optimize the performance be decreasing the number of rows and columns in the grid.

Regards,
Angel Petrov
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Grid
Asked by
pedrotti
Top achievements
Rank 1
Answers by
Angel Petrov
Telerik team
pedrotti
Top achievements
Rank 1
Share this question
or