ESRI add-in: Difference between revisions

From Wildsong
Jump to navigationJump to search
Brian Wilson (talk | contribs)
Created page with "== Create an add-in == First create the template using the ESRI add-in assistant. Add your code. (Just like that no additional help needed. :-) This will give you a makeadd..."
 
Brian Wilson (talk | contribs)
Line 9: Line 9:
I use Visual Studio set to run makeaddin.py when I do an F5 build.
I use Visual Studio set to run makeaddin.py when I do an F5 build.


I have ArcMap set to search my source directory on startup. (See [[Data driven pages]].)
I have ArcMap set to search my source directory on startup. (See [[Data Driven Pages]] for help.)
Then I only need to reload ArcMap to test new versions.
Then I only need to reload ArcMap to test new versions.



Revision as of 16:48, 1 October 2018

Create an add-in

First create the template using the ESRI add-in assistant.

Add your code. (Just like that no additional help needed. :-)

This will give you a makeaddin.py script that you can run to build the .esriaddin file.

I use Visual Studio set to run makeaddin.py when I do an F5 build.

I have ArcMap set to search my source directory on startup. (See Data Driven Pages for help.) Then I only need to reload ArcMap to test new versions.

What's in an esriaddin file?

I opened one in emacs. It looks like this

 Filemode      Length  Date         Time      File
 ----------  --------  -----------  --------  -------------------------------
 -rw-rw-rw-      1897  23-May-2018  15:22:30  config.xml
 -rw-rw-rw-       694  19-Apr-2018  12:18:14  README.txt
 -rw-rw-rw-      2834  30-Apr-2018  10:27:38  makeaddin.py
 -rw-rw-rw-     11951  20-Apr-2018  10:19:58  Images/cc_logo_64x64.png
 -rw-rw-rw-     27711  19-Apr-2018  10:12:54  Images/ormap.png
 -rw-rw-rw-      4543  23-May-2018  12:24:52  Install/ccmap.py
 -rw-rw-rw-      5859  23-May-2018  12:07:48  Install/arc_utilities.py
 -rw-rw-rw-      4293  18-May-2018  12:08:28  Install/cancellations.py
 -rw-rw-rw-      3182  28-Mar-2018  11:36:54  Install/mapnum.py
 -rw-rw-rw-      4592  11-May-2018  16:28:44  Install/MXDReport_tool.py
 -rw-rw-rw-      3932  29-Mar-2018  11:33:26  Install/mxd_report.py
 -rw-rw-rw-     10504   3-Apr-2018  16:52:26  Install/ormapnum.py
 -rw-rw-rw-      3400   3-Apr-2018  16:03:32  Install/printMaps.py
 -rw-rw-rw-      7128  21-May-2018  16:30:22  Install/PrintMaps_tool.py
 -rw-rw-rw-     13514  18-May-2018  12:37:22  Install/zoomToMapNumber.py
 -rw-rw-rw-      4336  21-May-2018  16:30:22  Install/ZoomToMapNumber_tool.py
 -rw-rw-rw-       186  12-Apr-2018  16:40:12  Install/__init__.py
 -rw-rw-rw-      2547  25-Apr-2018  16:49:52  Install/ORMAP_config.py
 ----------  --------  -----------  --------  -------------------------------
               113103                         18 files

If you look in my source code you will see ONLY ccmap.py in the Install/ folder. I tweaked the makeaddin.py script to copy all the other files in there.