AnsweredAssumed Answered

How to Create Field in Table, Standalone Table, Feature Layer, or Feature Class?

Question asked by jameskennedy2265 on Jun 12, 2019
Latest reply on Jun 12, 2019 by jameskennedy2265


I am working on porting old applications from ArcObjects to the new ArcGIS Pro SDK and have a significant question. I've looked through the questions and the examples, but I am stumped on this one.


How can I create a field in a Table?

in a Standalone Table?

in a Feature Layer?

in a Feature Class?


In ArcObjects this was quite easy as you could do 

IField field = new Field();
IFieldEdit fieldEdit = (IFieldEdit)field;
fieldEdit.Name_2 = fieldName;
fieldEdit.Type_2 = fieldType;


now I must use ExecuteToolAsync?


How can I use this, is there a good example of someone adding a field?