Select to view content in your preferred language

Get the changed feature on Python Addin extension event onChangeFeature

880
7
04-07-2014 03:56 AM
LuizOliveira
Deactivated User
I'm doing tests with python addin, capturing the event onChangeFeature to can manipulate fields of the changed feature.
I could capture the event, but the event don't give me the changed feature.
I believe there is a simple way to get the changed feature, right?
How can i do it?
Tags (2)
0 Kudos
7 Replies
LuizOliveira
Deactivated User
Anyone have idea for this problem?
0 Kudos
JamesCrandall
MVP Alum
I'm doing tests with python addin, capturing the event onChangeFeature to can manipulate fields of the changed feature.
I could capture the event, but the event don't give me the changed feature.
I believe there is a simple way to get the changed feature, right?
How can i do it?


I wasn't aware that a Python Add-In had an OnChangeFeature event.  Could you show us what you are testing? 

An Add-In could have a ButtonClass with an onClick event or a ToolClass can have onMouseDown, onDblClick, onRectangle, etc... events but no such thing as a way to capture onChangeFeature. 

http://resources.arcgis.com/en/help/main/10.1/index.html#/What_is_a_Python_add_in/014p00000025000000...

Are you confusing this with an ArcObjects COM component?
0 Kudos
LuizOliveira
Deactivated User
I wasn't aware that a Python Add-In had an OnChangeFeature event.  Could you show us what you are testing? 

An Add-In could have a ButtonClass with an onClick event or a ToolClass can have onMouseDown, onDblClick, onRectangle, etc... events but no such thing as a way to capture onChangeFeature. 

http://resources.arcgis.com/en/help/main/10.1/index.html#/What_is_a_Python_add_in/014p00000025000000...

Are you confusing this with an ArcObjects COM component?


Hi James,

I'm not confusing with ArcObject COM component, it is new for me too.

Look this link http://resources.arcgis.com/en/help/main/10.1/index.html#/application_extension/014p00000018000000/

I'm just following the ESRI sample to create a python add-in application extension, and assign-in to listen the ChangeFeatureEvent.

When i was testing to do in this way (python add-in) i saw a differences between AO ClassExtension x Python add-in Application Extension

In AO Class extension we need to "install" in all class that we want to this extension will be called.

In Python extension we need to enable the extension that we create on Extensions toolbar and then the python application extension will listen all layers (registered events on python add-in app extension)
0 Kudos
JamesCrandall
MVP Alum
Hi James,

I'm not confusing with ArcObject COM component, it is new for me too.

Look this link http://resources.arcgis.com/en/help/main/10.1/index.html#/application_extension/014p00000018000000/

I'm just following the ESRI sample to create a python add-in application extension, and assign-in to listen the ChangeFeatureEvent.

When i was testing to do in this way (python add-in) i have seen a differences between AO ClassExtension x Python add-in Application Extension

In AO Class extension we need to "install" in all class that we want to this extension will be called.

In Python extension we need to enable the extension that we create on Extensions toolbar and then the python application extension will listen all layers (registered events on python add-in app extension)


Ah I see.  All of the google results reference ArcObjects development.
0 Kudos
LuizOliveira
Deactivated User
In my tests, the registered events on python app extension add-in was fired fine!

The unique problem is: I need the feature owner of this fired event. (like AO does with class extension)

If you need, i can send the python add-in and the code base here.
0 Kudos
JamesCrandall
MVP Alum
In my tests, the registered events on python app extension add-in was fired fine!

The unique problem is: I need the feature owner of this fired event. (like AO does with class extension)

If you need, i can send the python add-in and the code base here.


I have yet to build an Add-In Extension and unfamiliar with it's features.
0 Kudos
LuizOliveira
Deactivated User
I have yet to build an Add-In Extension and unfamiliar with it's features.


Ok, i understand, take your time.

If you have any problems to create the first app extension, just call me and i'll help you.

I had some problems until i could to put the add-in to work fine.
0 Kudos