您好,添加字段需要通过fieldInfos.Add()添加。可以参考以下代码:
FieldInfo fieldInfoNew = new FieldInfo();
fieldInfoNew.Name = fieldName;
fieldInfoNew.Type = FieldType.Text;
fieldInfoNew.Caption = fieldName;
fieldInfoNew.IsRequired = false;
m_datasetVector.FieldInfos.Add(fieldInfoNew);//添加重叠字段
希望可以帮助到您!