nqazi

Python Addin Testing problem

Discussion created by nqazi on Apr 1, 2013
I am learning how to use Python addin. after creating project i added a button as described in help 10.1  and then  test it However when i double click  makeaddin.py script to run it than its just open in the editor i.e. does not run. I also tried to run  makeaddin.py script from IDE than i receive following  error:
Traceback (most recent call last):
  File "C:\NHQ_Project_WWTP\timswork\addinpythonwork2ndtry\makeaddin.py", line 5, in <module>
    current_path = os.path.dirname(os.path.abspath(__file__))
NameError: name '__file__' is not defined
i appreciate any advice how to run makeaddin.py

I have followed this links.
http://resources.arcgis.com/en/help/main/10.1/index.html#//014p00000025000000
after installation , i created a project following instruction given in this link
http://resources.arcgis.com/en/help/main/10.1/index.html#/project/014p00000022000000/
and
http://resources.arcgis.com/en/help/main/10.1/index.html#/button/014p0000001z000000/

After this i want to test it and i followed the following link:
http://resources.arcgis.com/en/help/main/10.1/index.html#/Testing_an_add_in/014p00000026000000/

Outcomes