Automatically determining projection zone & using that information 2 select prj file

03-14-2014 09:55 AM
by Anonymous User
Not applicable
Hi, I'm trying to automatically select projection files based on the zone that a feature is in.  I obtained the state plane zone file here from an ESRI Web site. Then I used the select layer by location command in model builder (see below) to select which zone that feature is in (I'm not sure how I will deal with features within multiple zones but I might just get a centroid for a feature.  Then I use the get Field value to get that field value for the selected record.   I exported the contents of the projections in arcgis using sample python code from the arcgis  forum here (see number six).   I also exported the feature class with all the zones into a shape file and brought them into excel.  My thought was to match up these records.   But I"m not sure how to go further.  Please let me know if you have suggestions.

0 Kudos
3 Replies
Esri Notable Contributor

That dataset was originally built in ArcInfo Workstation where the FIPS code was the way to specify a state plane zone. It hasn't been updated to include any well-known IDs, for instance. I'm attaching a list of all state plane zones on all supported geographic coordinate systems and units (meters, US survey feet, Int'l feet) with their well-known IDs.

0 Kudos
by Anonymous User
Not applicable
Thanks Melita!!! :cool: I took the zones file and matched it up with the shape file of the zones and have attached it here: ( [ATTACH=CONFIG]32215[/ATTACH] ).   If you look below, I have updated the model builder a bit.   The output of the "Get Field Value" is the right coordinate system.  But I need to turn it into a blue box.  I"m going to work on this some more.

0 Kudos
Occasional Contributor II
Hi Tom, I've written a script to do exactly this.  I use it all the time.  It selects a state plane zone based on the current extent of the data frame, and if the extent spans more than one zone it will add the zone layer to the display so the user can zoom in and rerun the tool.  It shouldn't be too difficult to modify the code for your own needs.  I've packaged the toolbox, prj files, and script in this zipfile.  Just unzip this folder and add the toolbox to ArcMap.  Make sure all the little files stay in the folder just as they are.  Are you using 10.1?  If so, I may take this opportunity to finally turn this concept into an addin.

0 Kudos