다음을 통해 공유


GanttStyleInfo.AddBarStyle Method

Adds a bar style definition to a Microsoft.SharePoint.JSGrid Gantt chart.

Namespace:  Microsoft.SharePoint.JSGrid
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public Sub AddBarStyle ( _
    barStyle As GanttBarStyle _
)
'Usage
Dim instance As GanttStyleInfo
Dim barStyle As GanttBarStyle

instance.AddBarStyle(barStyle)
public void AddBarStyle(
    GanttBarStyle barStyle
)

Parameters

Remarks

This example demonstrates how to use the AddBarStyle method to create a summary Gantt bar style.

   /*Summary Bar Style*/
   styleInfoObj. AddBarStyle(new GanttBarStyle(
   CustomBarStyle.Summary, BarShape.TopHalf, Color.Gray, BarPattern.Solid,
   BarEndShape.HomePlateDown, Color.Gray, BarShapePattern.Filled,
   BarEndShape.HomePlateDown, Color.Gray, BarShapePattern.Filled,
   "START_DATE", "FINISH_DATE", 1));
   'Summary Bar Style
   styleInfoObj. AddBarStyle(New GanttBarStyle(CustomBarStyle.Summary, BarShape.TopHalf, Color.Gray, BarPattern.Solid, BarEndShape.HomePlateDown, Color.Gray, BarShapePattern.Filled, BarEndShape.HomePlateDown, Color.Gray, BarShapePattern.Filled, "START_DATE", "FINISH_DATE", 1))

See Also

Reference

GanttStyleInfo Class

GanttStyleInfo Members

Microsoft.SharePoint.JSGrid Namespace