Code in field Default Value for Unique ID?

2911
2
Jump to solution
06-30-2015 09:24 AM
by Anonymous User
Not applicable

Hello all,

I am wondering if I can do something to automate this process. Currently I add a point to my feature class and I manually type in "N" + the OBJECTID in my "UniqueID" field. Is there a way I can code the field default value to be "N" + !OBJECTID! so it just adds that value when I create the point?

Thanks!

Tags (1)
0 Kudos
1 Solution

Accepted Solutions
FreddieGibson
Occasional Contributor III

With python this would involve post processing (i.e. after you add features you'd need to run a script to update these values). If you wanted to execute this as you create features you would need either an editor extension (Python or ArcObjects) or a feature class extension (ArcObjects). In the editor extension you would need to listen for the on create event.

An easier option may be to use the Attribute Assistant to automate this task.  You could leverage the Dynamic Table functionality within it that could automate populating your fields with the needed values.

Dynamic Value Table

http://resources.arcgis.com/en/help/localgovernment/10.2/index.html#/Dynamic_Value_table/028s0000008...

View solution in original post

2 Replies
FreddieGibson
Occasional Contributor III

With python this would involve post processing (i.e. after you add features you'd need to run a script to update these values). If you wanted to execute this as you create features you would need either an editor extension (Python or ArcObjects) or a feature class extension (ArcObjects). In the editor extension you would need to listen for the on create event.

An easier option may be to use the Attribute Assistant to automate this task.  You could leverage the Dynamic Table functionality within it that could automate populating your fields with the needed values.

Dynamic Value Table

http://resources.arcgis.com/en/help/localgovernment/10.2/index.html#/Dynamic_Value_table/028s0000008...

by Anonymous User
Not applicable

Brilliant! This Attribute Assistant is Awesome! I had heard about it briefly in the past but never took the time to learn it or implement it. I did that yesterday and it's a dream come true.

Thank you so much for reminding me about it.

Cheers!

0 Kudos