When I perform Raster to polygon conversion using tool, sometimes it creates a field named "GRIDCODE", sometimes the field name is "grid_code". Why does it create random name of a field?

1 Answer 1


The online help for Raster To Polygon says:

The Field parameter allows you to choose which attribute field of the input raster dataset will become an attribute in the output feature class. If a field is not specified, the cell values of the input raster (the VALUE field) will become a column with the heading Gridcode in the attribute table of the output feature class.

However, I ran a test using it on a PNG image with an output file geodatabase feature class and a field called grid_code was created so the documentation seems to be in error or at least deficient.

I have not been able to find a procedure that will produce a field called GRIDCODE or Gridcode.

  • 1
    Thanks. It was my mistake. I was doing raster to polygon using both Raster To Polygon tool and IConversionOp.RasterDataToPolygonFeatureData Method to test if I my code doing right thing or not. Tool gave "grid_code" and code gave "GRIDCODE". Because of I ran those two simultaneously and add some exceptional case to test, I thought because of those cases, this random thing happened.
    – Emi
    May 19, 2013 at 11:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.