1: /// <summary>
2: /// 获得坐标系统
3: /// </summary>
4: /// <param name="pFeatureClass"></param>
5: /// <returns></returns>
6: public static ISpatialReference getSpatialReference(IFeatureClass pFeatureClass)
7: {
8: IGeoDataset pGeoDataset = pFeatureClass as IGeoDataset;
9: return pGeoDataset.SpatialReference;
10: }
通过FeatureClass的FeatureDataset.Name属性可以直接获取其所在的数据集名称,注意这里的数据集名称为全称,如果是SDE中的数据集,那么名称会包含表空间的前缀!
时间: 2024-10-22 15:21:57