Select to view content in your preferred language

Add "Fields" to Polygons for passing to GeoProcess

597
1
07-08-2010 11:54 AM
James_H_Cutts_III
Emerging Contributor
I have a Geoprocess which requires the following parameter:
Parameter: Boone_County

      Data Type: GPFeatureRecordSetLayer
      Display Name: Boone_County
      Direction: esriGPParameterDirectionInput
      Default Value:
            Geometry Type: esriGeometryPolygon
            Spatial Reference: 26915
            Fields:
                + OBJECTID_1 (Type: esriFieldTypeOID, Alias: OBJECTID_1)
                + OBJECTID (Type: esriFieldTypeDouble, Alias: OBJECTID)
                + STATEFP (Type: esriFieldTypeString, Alias: STATEFP)
                + COUNTYFP (Type: esriFieldTypeString, Alias: COUNTYFP)
                + COUNTYNS (Type: esriFieldTypeString, Alias: COUNTYNS)
                + CNTYIDFP (Type: esriFieldTypeString, Alias: CNTYIDFP)
                + NAME (Type: esriFieldTypeString, Alias: NAME)
                + Shape (Type: esriFieldTypeGeometry, Alias: Shape)
                + Shape_Length (Type: esriFieldTypeDouble, Alias: Shape_Length)
                + Shape_Area (Type: esriFieldTypeDouble, Alias: Shape_Area)
      Parameter Type: esriGPParameterTypeRequired
      Category:


I know how to pass the Polygon, but I have to have the "CNTYIDFP" field as well.  How do I go about adding the fields?

Here's a snippet of the code:
 var driveTime:FeatureSet = new FeatureSet();
 driveTime.features = driveTimeA;
 var params:Object = { "Boone_County": driveTime };
 cursorManager.setBusyCursor();
 hothBioMass_Raster.execute(params);
Tags (2)
0 Kudos
1 Reply
DasaPaddock
Esri Regular Contributor
You can add fields to the Graphics attributes.

e.g. For each graphic in your driveTimeA Array, you can call graphic.attributes.CNTYIDFP = "foo";
0 Kudos