Customized forms?

3064
5
12-03-2010 03:05 PM
KateSchaefer
New Contributor II
Hey everyone,

I have a python script for data entry and I would like to create a customized entry form that people could use. In 9.3 you could create a vba form, is there a version of this in 10? 

The only option I can find that's close doing the generic 'tool' screen, but for batch data entry I don't want them to have to click on the tool button for every record. Am I missing something?

Thanks in advance!
Tags (2)
0 Kudos
5 Replies
LoganPugh
Occasional Contributor III
The Python implementation and script tool framework in ArcGIS is not really designed for data entry, more for data management and analysis on entire datasets or selections of datasets. There are a few Python GUI frameworks such as PyQT and wxPython, but as of yet these are not well supported or documented for use with ArcGIS. Your best bet is to learn C# or VB.NET and write an add-in (ArcGIS 10) or extension (9 and 10). The free Visual Studio Express editions integrate well with ESRI's software development kits (SDK) for ArcGIS, and it's pretty easy to get up and running, though learning ArcObjects is likely going to be the hardest part.

Note that if you're really determined you can use ArcObjects in Python using the comtypes module. See Mark Cederholm's presentation here: http://www.pierssen.com/arcgis/upload/misc/python_arcobjects.pdf
0 Kudos
KateSchaefer
New Contributor II
Great! Thanks for the help!
0 Kudos
karlkliparchuk
New Contributor
In python the Tkinter library allows you to create forms.  just import it to your py script, then you can start building menus.
0 Kudos
MikeHunter
Occasional Contributor
I don't know about pyqt, but wxpython will not work with ArcGis--just doing an 'import wx' in the python window, or in a tool script, will crash the entire application (event loop clash, I suspect).  However, you can use wxpython outside the app framework and communicate with it using comtypes and the approt process.   As mentioned above, Cederholm's instructions will get you started nicely.

Mike
0 Kudos
BenVan_Kesteren1
Occasional Contributor III
Just reviving this thread as I have recently done the intro to geoprocessing scripts course, and am interested in creating a form type applet thing for data entry.

Has anyone created a form for data entry? Can you please provide a screen grab to see if its the type of thing we are looking do develop and implement?

I have attached the hand written form that is submitted by the field staff, which we plot a point in the GIS and enter the attributes. Currently the data is entered into the attributes table directly, and its not a very 'neat' way of doing this. Before I started with this organisation they apparently had a VBA script type form which is now outdated/obsolete with the new versions of ArcGIS (10+).

Anyone out there that can show me what is possible?
[ATTACH=CONFIG]32754[/ATTACH]
Thanks
-Ben
0 Kudos