Example #1
0
 // Check whether a specific item needs to be filtered out.
 private static bool IsFilteredOut(GanttChartItem item)
 {
     // The current implementation checks whether the content (returned by ToString method) of the item ends with "(filtering)".
     // Optionally, you may modify the code below to apply a custom sort implementation based on specific requirements.
     return(item.ToString().EndsWith("(filtering)"));
 }
Example #2
0
 // Compare two items and return -1 if the items are specified in ascending order, 0 if the items are similar, or +1 if the items are in specified descending order.
 private static int Compare(GanttChartItem item1, GanttChartItem item2, string columnHeader)
 {
     // The current implementation compares the content (returned by ToString method) of the two items.
     // Optionally, you may modify the code below to apply a custom sort implementation based on column header and specific requirements.
     return(string.Compare(item1.ToString(), item2.ToString()));
 }