This document is archived and information here might be outdated.  Recommended version.


IDatasetContainer.AddDataset Method (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Geodatabase > ESRI.ArcGIS.GeoDatabase > Interfaces > ID > IDatasetContainer Interface > IDatasetContainer.AddDataset Method
ArcGIS Developer Help

IDatasetContainer.AddDataset Method

Adds a dataset to the dataset collection.

[Visual Basic .NET]
Public Sub AddDataset ( _
    ByVal datasetToAdd As IDataset _
)
[C#]
public void AddDataset (
    IDataset datasetToAdd
);
[C++]
HRESULT AddDataset(
  IDataset* datasetToAdd
);
[C++]
Parameters
datasetToAdd [in]

datasetToAdd is a parameter of type IDataset*

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Remarks

When calling this method on feature datasets, both the XY and Z spatial reference systems of the dataset (if applicable) must match those of the feature dataset.

See Also

IDatasetContainer Interface