0

I have a feature class.

IFeatureClass AOIfc = AOIfws.OpenFeatureClass("BrigadeAOI");

I need to be able to put this feature class into a feature dataset that is newly created. The following line of code doesn't work for me.

IFeatureDataset AOIfd = AOIfc.FeatureDataset;

How do I accomplish this?

1
  • Could you please tag this post with the appropriate software/languages? Thanks
    – Aaron
    Commented May 29, 2013 at 15:03

1 Answer 1

1

You might be able to do this using IDatasetContainer.AddDataset.

From the IDatasetContainer documentation:

The IDatasetContainer interface lets you move datasets between feature datasets and workspaces. Both objects implement the interface. It should only be used to move datasets between feature datasets and the workspace level within a single workspace, however; it cannot be used to transfer datasets from one workspace to another.

1
  • Thank you for your help. I ended up just doing this using ArcCatalog. I won't try to create this in the code. Commented Jun 3, 2013 at 15:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.