I'm tring to create simple RadOrgChart page. And I have to bind it by DataTable. I did, but it doesnt work.
My Telerik version is 2011.3.1115.40.
Here is my code;
And my Cs codes,
And I attached my DataTable result panel picture.(dt object preview)
My Telerik version is 2011.3.1115.40.
Here is my code;
<%@ Page Title="" Language="C#" MasterPageFile="~/Controls/MasterPages/User.master" Theme="Default" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="Sections_OrgChart_Default" %><asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server"></asp:Content><asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server"><telerik:RadOrgChart runat="server" ID="RadOrgChart1" ></telerik:RadOrgChart></asp:Content>And my Cs codes,
using System;using System.Collections.Generic;using System.Linq;using System.Web;using System.Web.UI;using System.Web.UI.WebControls;using Getron.AAM;using Getron.AAM.EntityManagement;using Getron.Core.Base.Objects;using System.Data;public partial class Sections_OrgChart_Default : EntityProtectedPage{ protected void Page_Load(object sender, EventArgs e) { OrgSchema osch = new OrgSchema(); QueryEntity qent = new QueryEntity(); qent.QueryEntityType = Getron.Core.Enums.EQueryEntityType.WhereCondition; qent.Query = "SupervisorId=@SupervisorId"; Getron.DBInterface.Parameter p0 = new Getron.DBInterface.Parameter("@SupervisorId", ParameterDirection.Input, DbType.Int64, 0); p0.Value = 23; qent.Parameters.Add(p0); DataTable dt = new DataTable(); dt = osch.GetCustomViewAll("OrgSchemaAllData", new List<string>() { "SystemUserIntCode", "SystemUserName", "SuperVisorId" }, qent); RadOrgChart1.DataTextField = "SystemUserName"; RadOrgChart1.DataFieldID = "SystemUserIntCode"; RadOrgChart1.DataFieldParentID = "SupervisorId"; RadOrgChart1.DataSource = dt; RadOrgChart1.DataBind(); }}And I attached my DataTable result panel picture.(dt object preview)