2,021 reputation
315
bio website
location Mankato, MN
age 28
visits member for 2 years, 10 months
seen 4 hours ago

LinkedIn

Recently developed a python package to interact with the ArcGIS REST API


Jun
25
comment Creating polygon geometry using points array
Ah, I should point out that my suggestion only works for version 10.1 and beyond. Sorry for the confusion.
Jun
25
comment Creating polygon geometry using points array
Yes, I would do as Vince says and add a spatial reference, otherwise the polygon has no idea where it is supposed to be. Also, you can set up the wgs by passing in a well-known ID (WKID) rather than referencing a .prj file: wgs = arcpy.SpatialReference(4326)
Jun
16
comment Using Google API within Python and applying to ArcMap?
Haha, in @ian's defense, an edit was made to this question after he posted that asking how to get it into a toolbox.
Jun
15
comment Guidelines for using ArcObjects from Python
Thanks @Michael Miles-Stimson. I will give it another shot. If I can't figure it out, I'll post a new question with my current code.
Jun
12
comment Guidelines for using ArcObjects from Python
Wow, thank you so much for posting this! I have had some struggles understanding the ArcObject Diagrams. It is nice to have some input from someone like yourself who comes from the other side of the fence (lots of .NET ArcObjects experience). One thing I have had some difficulties with is accessing a feature class that resides in a feature dataset via comtypes and python. I think in the past I have tried opening the feature data set first and then the feature class but didn't have any luck (getting some null pointers). Do you have any python samples for that?
Jun
11
comment Arcpy scripts run time dialog keeps deactivating tkinter window
After reading your post again, you could try introducing a bit more logic into your script tool. For example, you could have an optional parameter that allows the user to enter any extra field names not found in the target feature using a String data type as a multiple input parameter.
Jun
11
comment Arcpy scripts run time dialog keeps deactivating tkinter window
I have never tested, but for what it's worth I read that Tkinter based widgets do not play nicely in ArcMap.
Jun
8
comment Where are coordinate system files saved when using the ArcGIS Citrix app?
I think Esri stopped including the .prj files at version 10.1. They are now referenced using well-known IDs (WKID).
Jun
5
comment When building fieldmappings, how do I handle the SHAPE field?
Just as a catch all, it may be best to filter all non-required fields: fields = [f.name for f in arcpy.ListFields(fc) if not f.required]. This will also exclude fields like OBJECTID.
Jun
5
comment Arcpy strip '{ and ]' from list return
is it returning a list? Why not just use "NEW_SELECTION", "town = '{}'".format(selection[0]))...Haha, fancy seeing you here Wayne!!
Jun
5
comment Arc Python add in - dynamic combo populate
That is pretty cool, I guess I never thought of it that way. As per my post, I have always used buttons to execute the query, but I suppose that wasn't necessary after all. I never thought to build that logic right into the onSelection method. Does this work pretty fast?
Jun
4
comment Is there a way to copy attributes from a point layer in an overlaying polygon layer? in arcGIS10
Use a spatial join.
Jun
3
comment Select by attributes with user input using Python
Perhaps instead of just having a text parameter for the stNum variable, you can just change that parameter to a SQL data type and that way you can use the Select By Attribute GUI. You will have to make sure that it is obtained from your Address Feature class though.
Jun
3
comment Convert length in decimal degrees to feet
I think the easiest thing to do would be to reproject your data and rerun the near tool so you can get back some useful units.
Jun
3
comment Consume gp service from within ArcMap and add results to display
You could try exporting the model to python script and set the arcpy.env.addOutputsToMap = True. Then add a return statement to return your output clipped variable. Another option is to use arcpy.mapping.AddLayer(df, arcpy.Layer(your_clip_variable)) to explicitly make sure it is added to the TOC.
Jun
2
comment ArcObjects WPF Select layer in legend
The .NET ArcGIS Runtime does not use ArcObjects, it uses its own .NET SDK (that is built on top of ArcObjects). That being said, have a look at the Layers namespace in the API Documentation: developers.arcgis.com/net/desktop/api-reference
May
29
comment Determining the cosine of the angles between two lines using dot product
I should clarify that gets you the angle between two points.
May
28
comment Checking for overlaps using python
Are you using ArcGIS 10.0? If you are at 10.1 or beyond, I would suggest switching to the arcpy.da.SearchCursor. I have noticed geometry operations seemed a little buggy at version 10 with the old Search Cursor. It seemed like I was always getting the ever so helpful ERROR 999999.
May
19
comment Set polygon boarders to transparent in python
You cannot control the symbology explicitly with arcpy. What you can do is save a Layer File (.lyr) with that symbology and then use arcpy.management.ApplySymbologyFromLayer where you would reference your .lyr file.
May
15
comment How to edit PostgreSQL geodatabase table using ArcPy?
Thank you for posting this...This is definitely something ESRI needs to put in their documentation.