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
80
How to bold the text for parents without children in UltraWinGanttView
posted

Hi team -

Thanks in advance for reviewing my question.  

After successfully implementing a Gantt through databinding to UltraWinGanttView, I notice that any of the parents in my grid are not displayed in bold font when there are no children associated with it.  I want the parents bolded even when there are no children and I can't quite figure out how to get access to that element (band?).  If you could supply me with information on how to implement this change, or even how to enumerate over my WinGanttView and directly make the change to the parent, I would greatly appreciate it.  

Any help you can provide is greatly appreciated.

Screenshot for illustration:

Screenshot

  • 29105
    Verified Answer
    Offline posted

    Hello Brent,

    Yes, the ganttview automatically bolds the parent tasks by default. To ensure that every parent task is bold you could loop through the parent tasks collection and look to see if there any child tasks. If there aren't, then you can set the Bold property exposed from the task object

    foreach (Task tasks in this.ultraCalendarInfo1.Tasks)
    {
       if (tasks.Tasks.Count == 0)
          {
             tasks.GridSettings.RowAppearance.FontData.Bold = Infragistics.Win.DefaultableBoolean.True; 
          }
    }

    Let me know if you have any questions regarding this matter.