赞
踩
说明:该代码是调用GP工具实现
filePath:输入路径,dwg文件路径,比如:C:/Documents and Settings/Administrator/桌面/dwg/aa.dwg
outPutPath:输出路径,shape文件路径,比如:C:/Documents and Settings/Administrator/桌面/shp/bb.shp
private void ConvertCAD2Shp(string filePath, string outPutPath)
{
IGPProcess tools = null;
cadtoshpTools = new CADtoFeatureClass();
cadtoshpTools.input_CAD_file = filePath;
cadtoshpTools.output_feature_class = outPutPath;
tools = cadtoshpTools;
ESRI.ArcGIS.Geoprocessing.IGeoProcessorResult result = gp.Execute(tools, null) as ESRI.ArcGIS.Geoprocessing.IGeoProcessorResult;
}
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。