if ce.getAttributeSource(..) == "DEFAULT" : return 8 ( or whatever the default is ), return this as hardcoded value if ce.getAttributeSource(..) == "USER" : return value of getObjectAttr(..) ..
You need to convert it to a string first using 'str'
Example:
Souce_Type = ce.getAttributeSource(..)
if str(Souce_Type) == 'DEFAULT' :
return 8
if str(Souce_Type) == "USER" :
return value of getObjectAttr(..)
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.