programmatically add a unique ID to feature layer attribute

639
0
12-01-2016 02:42 PM
by Anonymous User
Not applicable

Hi all, 

I am using ken's code to update/add projects to feature layer:

array.forEach(featureSet, function (feature) {
feature.attributes.ID= autogenerate;
  feature.attributes.Priority = registry.byId('cboPriority').get("value");
  feature.attributes.Management = registry.byId('cboManagement').get("value");
  feature.attributes.Criteria1 = registry.byId('cboCriteria1').get("value");
});

layerFeatureLayer.applyEdits(null, featureSet, null, function () { console.log("Features updated!"); }, function (error) { console.log("Features not updated! ", error); });‍‍‍‍‍‍‍

Now I am looking to add a field ID that would get auto generated when users create a buffer. Is it possible?

0 Kudos
0 Replies