# Distribution Table Programming Considerations

## Content



The [Chart3DContourLevel](/componentone/api/win/online-chart3d/dotnet-framework-api/C1.Win.C1Chart3D.4.8/C1.Win.C1Chart3D.Chart3DContourLevel.html) object controls the behavior of the distribution levels used to create contour levels and zones for a chart. One Chart3DContourLevel object is defined for each chart group.

The [NumLevels](/componentone/api/win/online-chart3d/dotnet-framework-api/C1.Win.C1Chart3D.4.8/C1.Win.C1Chart3D.Chart3DContour.NumLevels.html) property of the [Chart3DContour](/componentone/api/win/online-chart3d/dotnet-framework-api/C1.Win.C1Chart3D.4.8/C1.Win.C1Chart3D.Chart3DContour.html) object specifies the number of distribution levels to use in the chart. Any number between 2 and 100 is valid. If two are specified, no contour levels are drawn, and the entire chart is displayed as one zone.

By default, distribution levels are evenly spaced. To define distribution levels and spacing, use the **Add** method of the Chart3DContourLevel to create them. For example, the following code defines distribution levels at 1000, 2500 and 4200:

DOC-DETAILS-TAG-OPEN

DOC-SUMMARY-TAG-OPEN

To write code in Visual Basic

DOC-SUMMARY-TAG-CLOSE

```vbnet
With C1Chart3D1.ChartGroups(0).Contour.Levels
  .Add( 1000)
  .Add( 2500)
  .Add( 4200)
End With
```

DOC-DETAILS-TAG-CLOSE

DOC-DETAILS-TAG-OPEN

DOC-SUMMARY-TAG-OPEN

To write code in C#

DOC-SUMMARY-TAG-CLOSE

```csharp
Chart3DContourLevelsCollection levs;
levs = C1Chart3D1.ChartGroups[0].Contour.Levels;
levs.Add(1000);
levs.Add(2500);
levs.Add(4200);
```

DOC-DETAILS-TAG-CLOSE

To remove a distribution level, use the **Remove** method:

DOC-DETAILS-TAG-OPEN

DOC-SUMMARY-TAG-OPEN

To write code in Visual Basic

DOC-SUMMARY-TAG-CLOSE

```vbnet
C1Chart3D1.ChartGroups(1).Contour.Levels.Remove( 1000)
```

DOC-DETAILS-TAG-CLOSE

DOC-DETAILS-TAG-OPEN

DOC-SUMMARY-TAG-OPEN

To write code in C#

DOC-SUMMARY-TAG-CLOSE

```csharp
C1Chart3D1.ChartGroups[1].Contour.Levels.Remove( 1000);
```

DOC-DETAILS-TAG-CLOSE

At any time, revert to evenly spaced distribution levels by setting the [AutoDistribution](/componentone/api/win/online-chart3d/dotnet-framework-api/C1.Win.C1Chart3D.4.8/C1.Win.C1Chart3D.Chart3DContour.AutoDistribution.html) property to **True**. If this is done, the number of distribution levels in the chart will not change.

## See Also

[3D Chart End-User Interaction](/componentone/docs/win/online-chart3d/3dchartenduserintera)