.NET Add-in 'Goto Extent'

460
3
07-25-2011 01:39 AM
TonyCollins
Occasional Contributor
As you can tell from the title I expect, I'm a newbie in ArcObjects. I can't seem to find any real simple full examples to get going in creating a simple Add-in. Only snippets so I don't know what references to include.

At the moment I have a button that I can click to say 'Hello' which is cool to start with.

What I would like is to populate a combobox with a list of Districts, then when the button is pressed Arcmap goes to the extent or envelope of the associated polygon.

Could someone help me find some samples or give me some quick help?
0 Kudos
3 Replies
JeromeHaaland
Occasional Contributor
Tony,

This is a great question?  Being a learning programmer myself, I would really like to see the same examples.
0 Kudos
JohnHauck
Occasional Contributor II
Please see the 2011 Developer Summit technical sessions page. Here you can find various videos that may help with building up a firm base of knowledge for your efforts.

I know in the "ArcGIS 10 Desktop Developer Migration Topics" we had a basic example of migrating a VBA workflow to a .NET Add-In. The demo would allow you to click a button that would launch a form that had a combo box that would get populated with all of the values from a given field. You could select one of the values and it would select this feature in the map. Not exactly the same workflow that you are looking to accomplish but very similar. I think the bigger issue that this aims to help with is pointing out some of the common interactions you will have with the IDE for the basic things like adding references.
0 Kudos
amrutabildikar1
New Contributor
Tony,

I think you might want to implement following approach:

1. Create Addin using combobox
2. When you are selecting a �??District�?? from combobox, access the feature id of it
3. Use this feature id to get selectionset and then implement zoom to selected features.
4. Navigate to below mentioned link where Zoom to selected feature example is given

http://support.esri.com/en/knowledgebase/techarticles/detail/20913

Good luck!
0 Kudos