Hi,
I am new to this Arc Objects SDK platform.
I can able to get the feature class names from Geodatabase.
I want to display the field names of a feature class which is from Geodatabase.
Kindly anyone help me out in this. It will be more helpful if anyone has solution for this.
Solved! Go to Solution.
The IFeatureClass object has a Fields property which is a collection of all the fields.
You will need to iterate through each IField object in the IFields property. Get the count from the IFields and set a for loop. Get each IField object for each index and there is a Name object.
//fc is your featureclass object...
for(int i = 0; i < fc.Fields.FieldCount; i ++)
{
IField f = fc.Fields.get_Field(i);
string name = f.Name; //collect these...
}
Brent
The IFeatureClass object has a Fields property which is a collection of all the fields.
You will need to iterate through each IField object in the IFields property. Get the count from the IFields and set a for loop. Get each IField object for each index and there is a Name object.
//fc is your featureclass object...
for(int i = 0; i < fc.Fields.FieldCount; i ++)
{
IField f = fc.Fields.get_Field(i);
string name = f.Name; //collect these...
}
Brent
Thank you for your reply