OrgChartNodeDropEventArguments make LinkButton onClick false on first click

2 posts, 0 answers
  1. Peerayu
    Peerayu avatar
    6 posts
    Member since:
    May 2014

    Posted 25 Jun 2014 Link to this post

    Hi, I'm using Telerik 2014.1.403.45. I have the problem with the LinkButton in my RadOrgChart node.

    I put RadOrgChart in RadAjaxPanel. there are the LinkButtons in OrgChart Nodes. LinkButtons work correctly after page_load.
    However, if I dragged and dropped the node and then clicked on a LinkButton, it will only do postback to page_load but no CommandEventArgs . The events of the LinkButton only works on the second click.

    <telerik:RadAjaxPanel ID="panOrganize" runat="server" CssClass="OrganizeCanvas" LoadingPanelID="radAjaxLoadingPanel">
        <telerik:RadTabStrip ID="rtabOrganize" runat="server" MultiPageID="rmpOrganize" SelectedIndex="0" Width="100%" CssClass="FontBold" OnTabClick="rtabOrganize_TabClick">
                <telerik:RadTab CssClass="FontBold" Text="Organize Chart" />
                <telerik:RadTab CssClass="FontBold" Text="Position" Enabled="false" />
                <telerik:RadTab CssClass="FontBold" Text="User" Enabled="false" />
        <telerik:RadMultiPage ID="rmpOrganize" runat="server" SelectedIndex="0">
            <telerik:RadPageView ID="rpvOrgOrganize" runat="server" Width="100%">
                <telerik:RadOrgChart ID="radOrgChart" runat="server" Width="100%" CssClass="SpacingBottom20" LoadOnDemand="Nodes"
                    DataFieldID="OrgID" DataFieldParentID="ParentID"
                    EnableDragAndDrop="true" OnNodeDrop="radOrgChart_NodeDrop">
                        <asp:Panel ID="panNode" runat="server" CssClass="TemplateHolder">
                            <asp:Table ID="tbOrgChart" runat="server" Width="160px" Height="50px">
                                    <asp:TableCell RowSpan="3" Width="30px" VerticalAlign="Middle">
                                            <i class="fa fa-home FontSize28"></i>
                                    <asp:TableCell Width="5px" />
                                    <asp:TableCell VerticalAlign="Top">
                                        <asp:Label ID="lblTypeName" runat="server" Text='<%# Eval("OrganizationType.TypeName")%>' CssClass="FontBold" />
                                    <asp:TableCell Width="10px">
                                        <asp:LinkButton ID="lbtnSearch" runat="server" BorderStyle="None"
                                            CommandArgument='<%# Eval("OrgID")%>' CommandName='<%# Eval("Name")%>' OnCommand="lbtnSearch_Command">
                                            <i class="fa fa-search-plus"></i>
                                    <asp:TableCell RowSpan="2" />
                                    <asp:TableCell RowSpan="2" ColumnSpan="2" VerticalAlign="Top">
                                        <asp:Label ID="lblName" runat="server" Text='<%# Eval("Name")%>' />
                <telerik:RadContextMenu runat="server" ID="radContextMenu" CssClass="CustomContextMenu" Skin="Default" OnClientItemClicked="onClientItemClicked">
                        <telerik:RadMenuItem Text="Add" CssClass="rmAdd" Value="Add" />
                        <telerik:RadMenuItem Text="Edit" CssClass="rmEdit" Value="Edit" />
                        <telerik:RadMenuItem Text="Remove" CssClass="rmRemove" Value="Remove" />
                <telerik:RadWindow ID="radWindow" runat="server" AutoSize="true" Modal="true" Behaviors="Close"
                    VisibleTitlebar="true" VisibleStatusbar="false" OnClientClose="onClientClose">
            <telerik:RadPageView ID="rpvOrgPosition" runat="server" Width="100%">
            <telerik:RadPageView ID="rpvOrgUser" runat="server" Width="100%">

    Code Behind (C#)
    protected void Page_Load(object sender, EventArgs e)
    protected void radOrgChart_Load()
        radOrgChart.DataSource = String.Empty;
        //Get Data from EF
        List<Organization> listOrganize = organizeManager.GetOrganize();
        if (listOrganize.Count.Equals(0).Equals(false))
            radOrgChart.DataSource = listOrganize;
    protected void radOrgChart_NodeDrop(object sender, OrgChartNodeDropEventArguments e)
        //Update Database
        organizeManager.UpdateParentID(new Guid(e.SourceNode.ID), new Guid(e.DestinationNode.ID));
        //Load the new data
    protected void lbtnSearch_Command(object sender, CommandEventArgs e)
        //Open The second Tab, and set enable
        rtabOrganize_SetEnable(true, 1);
        //Set data into ViewState
        vsOrganizationID = e.CommandArgument.ToString();
        vsOrganizationName = e.CommandName;

  2. Nencho
    Nencho avatar
    1446 posts

    Posted 30 Jun 2014 Link to this post

    Hello Peerayu,

    I would suggest you to refer to the following forum thread, where the issue is explained and a possible solution is provided by Peter Filipov:


    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

  3. DevCraft R3 2016 release webinar banner
Back to Top