Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
175
Retrieve the end date and start date on the click of a specific GanttTimeEntry
posted

I am really new to infragistics Gantt Chart
I have a problem. I was making a Gantt Chart. I made a GanttSeries and in that GanttSeries I made different GanttItem and in each GanttItem I added different GanttTimeEntry which made my Gantt Chart ready. Now my problem
When I click on a specific GanttTimeEntry I need to retrieve the Start Time and End Time.
I know you can track the click event on OnChartDataClicked but the Primitive's will be blank or null. So I cannot get the data's of that specific GanttTimeEntry. Is there any other way to get this. Hope you understood my problem and will come with a helping hand.

Thanks in Advance

Parents
No Data
Reply
  • 175
    Verified Answer
    posted

    Hai,

    I have solved the Half of it. Here is what I have done till now.

    I started from the top ie making the GanttSeries global. Using GanttSeries you can find which Ganttitem was Clicked. Since the "Key" of the GantItem is unique it can be used to find which GanttItem. Something like below

    GanttItem ganttItem = ganttSeries.Items.FromKey(e.ColumnLabel);  e.ColumnLabel will give you the GanttItem "Key".

    Once you have found the GanttItem it is really easy to find which GanttEntryTime. Something like below can be done

    GanttTimeEntry time = ganttItem.Times[e.DataRow] i suppose e.DataRow will give you which GanttTimeEntry.

    so this will give you which GanttTimeEntry was clicked and now from that I can get the StartTime and EndTime and what all datas I want.

     But now my problem is that this "e.DataRow" is always 0. always giving me the first GanttTimeEntry inside the GanttItem. Even if I click on the 2nd GanttTimeEntry it will give me the 1st GanttTimeEntry. Hope you guys understood the problem. Somebody help me how to get the e.DataRow.

    Thanks in advance 

Children