创建点图层
IWorkspaceFactory pShpWksFact = new ShapefileWorkspaceFactory();
IFeatureWorkspace pFeatWks;
pFeatWks = (IFeatureWorkspace)pShpWksFact.OpenFromFile(filePath, 0);
const string strShapeFieldName = "Shape";
//定义属性字段
IFields pFields;
IFieldsEdit pFieldsEdit;
pFields = new FieldsClass();
pFieldsEdit = (IFieldsEdit)pFields;
IField pField = new FieldClass();
IFieldEdit pFieldEdit = new FieldClass();
pFieldEdit.Name_2 = strShapeFieldName;
pFieldEdit.Type_2 = esriFieldType.esriFieldTypeGeometry;
pField = (IField)pFieldEdit;
//定义几何属性
IGeometryDef pGeomDef = new GeometryDefClass();
IGeometryDefEdit pGeomDefEdit = new GeometryDefClass();
pGeomDefEdit = (IGeometryDefEdit)pGeomDef;
pGeomDefEdit.GeometryType_2 = esriGeometryType.esriGeometryPoint;
pGeomDefEdit.SpatialReference_2 = (ISpatialReference)new UnknownCoordinateSystem();
pFieldEdit.GeometryDef_2 = pGeomDef;
pFieldsEdit.AddField(pField);
pFields = (IFields)pFieldsEdit;
IFeatureClass pFeatureClass;
pFeatureClass = pFeatWks.CreateFeatureClass(fileName, pFields, null, null, esriFeatureType.esriFTSimple, strShapeFieldName, "");