Powered By ActiveOrgChart Evaluation Version
Assisted Solutions - Active Org-Chart - Demos
Active Org-Chart 1.0 Demos
© 2006-2010 Info Mason. All rights reserved

Return To Menu Dynamic entity moving Next Demo

ABOUT THIS DEMO:
To move an Entity, simple click it, drag the mouse, and release over another Entity. The orgDemo_EntityMove event will then be called, and the chart refreshed. A standard implementation of orgDemo_EntityMove simply makes an update, and then re-binds the data. View the code to see how this is accomplished.


Demo Area

Title here
   

    protected void orgDemo_EntityMove(object sender, WebOrgChart.MoveEventArgs e)
    {
        DataTable dt = ActiveOrgChart_LocalHelper.Data;
        DataRow[] dr = dt.Select("PersonID=" + e.SourceIdentity.ToString());
        if (dr.Length > 0) dr[0]["ParentPersonID"] = e.DestinationIdentity;
        BindOrgChart();
    }