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

Delete Row

1 Answer 39 Views
Grid
This is a migrated thread and some comments may be shown as answers.
John
Top achievements
Rank 1
John asked on 08 Jan 2010, 09:40 AM
I have code as below :

<telerik:RadGrid ID="RadGrid1" AllowFilteringByColumn="false" runat="server" GridLines="None"
                                                AllowPaging="true" AllowSorting="true" Width="100%" AutoGenerateColumns="false"
                                                EnableEmbeddedSkins="false">
                                                <ClientSettings EnableRowHoverStyle="true">
                                                    <Selecting AllowRowSelect="true" />
                                                    <Scrolling AllowScroll="true" UseStaticHeaders="True" SaveScrollPosition="True">
                                                    </Scrolling>
                                                    <ClientEvents OnRowSelected="rowSelected" />
                                                    <ClientEvents OnCommand="RadGrid1_Command" OnRowDeleted="RowDeleted"  OnRowDeleting="RowDeleting" />
                                                </ClientSettings>
                                                <MasterTableView CssClass="RadGrid_Web20" PagerStyle-Mode="NumericPages" ClientDataKeyNames="Customer_Contact_Id">
                                                    <Columns>
                                                        <telerik:GridBoundColumn SortExpression="Contact_Type" DataField="Contact_Type" HeaderText="Contact Type"
                                                            UniqueName="Contact_Type" ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left">
                                                        </telerik:GridBoundColumn>
                                                        <telerik:GridBoundColumn SortExpression="Contact_Name" DataField="Contact_Name" HeaderText="Contact Name"
                                                            UniqueName="Contact_Name" ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left">
                                                        </telerik:GridBoundColumn>
                                                        <telerik:GridBoundColumn SortExpression="Telephone" DataField="Telephone" HeaderText="Telephone"
                                                            UniqueName="Telephone" ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left">
                                                        </telerik:GridBoundColumn>
                                                        <telerik:GridHyperLinkColumn ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left"
                                                            DataNavigateUrlFormatString="mailto:{0}" DataNavigateUrlFields="Email" SortExpression="Email"
                                                            DataTextField="Email" HeaderText="Contact Email" ItemStyle-ForeColor="Blue">
                                                        </telerik:GridHyperLinkColumn>
                                                        <telerik:GridBoundColumn SortExpression="Email" DataField="Email" HeaderText="Contact Email"
                                                            UniqueName="MainEmail" Display="false" ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left">
                                                        </telerik:GridBoundColumn>
                                                        <telerik:GridBoundColumn SortExpression="ContactId" DataField="ContactId" HeaderText="ContactId"
                                                            UniqueName="ContactId" Display="false" ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left">
                                                        </telerik:GridBoundColumn>
                                                        <telerik:GridBoundColumn SortExpression="ContactTypeId" DataField="ContactTypeId"
                                                            HeaderText="ContactTypeId" UniqueName="ContactTypeId" Display="false" ItemStyle-HorizontalAlign="Left"
                                                            HeaderStyle-HorizontalAlign="Left">
                                                        </telerik:GridBoundColumn>
                                                        <telerik:GridBoundColumn SortExpression="Customer_Code" DataField="Customer_Code"
                                                            HeaderText="Customer_Code" Visible="false" ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left">
                                                        </telerik:GridBoundColumn>
                                                        <telerik:GridBoundColumn SortExpression="Customer_Contact_Id" DataField="Customer_Contact_Id"
                                                            UniqueName="Customer_Contact_Id" HeaderText="Customer_Contact_Id" Display="false"
                                                            ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left">
                                                        </telerik:GridBoundColumn>
                                                        <telerik:GridClientDeleteColumn ConfirmDialogType="RadWindow" ConfirmText="Are you sure you want to delete this row?"
                                                            HeaderStyle-Width="35px" ButtonType="ImageButton" ImageUrl="../Images/Delete.gif"
                                                            CommandName="Delete" />
                                                    </Columns>
                                                </MasterTableView>
                                            </telerik:RadGrid>


But previosly  OnRowDeleted="RowDeleted"  OnRowDeleting="RowDeleting" clinet events are getting fired but now 
in latest version of DDL its not working and i want delete button to diplay for each and every row.

1 Answer, 1 is accepted

Sort by
0
Hus Damen
Top achievements
Rank 1
answered on 08 Jan 2010, 10:49 AM
Hello John,

Have you tried whether deleting the duplicate ClientEvents tags solves the problem?

Thanks.
Hus
Tags
Grid
Asked by
John
Top achievements
Rank 1
Answers by
Hus Damen
Top achievements
Rank 1
Share this question
or