ARCGISENGINE给要素赋值时发现的一个问题

来源:互联网 发布:angularjs源码解读 编辑:程序博客网 时间:2024/06/05 23:41
IFeatureclass.findfield比iFields.findfield准确。
以后赋值记着用Ifeatureclass的示例。

之前我新建点图层赋值,一直setvalue出错,最后看自己以前的代码(很久之前),发现赋值时候,我的index是用的featureclass.findfield,而我用的是fields的findfield,我做了下实验,两者参数不同的,所以尽量用featureclass.findfield赋值。
 featureBuffer.Shape = pt as IGeometry; ;
featureBuffer.set_Value(Index, text);
featureCursor.InsertFeature(featureBuffer);
featureCursor.flush();
阅读全文
1 0
原创粉丝点击