Tuesday, July 31, 2012

Export Feature Selection to Geodatabase


From time to time, I like to do some handy tools that I just feel that someone will use it one day. Take the Twitter Extension for ArcGIS for instance that allows you to login to ArcMap with your twitter account and tweet from Arcmap. I got some emails from people who actually said they made use of the code. Some said that they created an account that will automatically tweet tasks done by users. Some used it to tweet when a warning when certain location on the map is viewed at a certain scale.




This time I developed a tool for ArcMap, that allows you to select some features in the map. Click a button and it will create a new layer, export your selection into a personal geodatabase in temporary location and set the new layer to that new source.


The new layer will contain the new selection ONLY, you can do many things with it, change symbology, use definition query etc..


And It works on any Data source doesn't matter if its SDE/PGDB/File GDB/Shape file.








Here is a Video






Here are some snaps.






















Download Script
Download Script

Change Layers Data Source in an MXD document


I have developed this tool only because our engineers needed it badly. It happens that its difficult to change the data source of a certain layer file to a new one. You have to do it one by one.


So this ESRI ArcMap tool help you do just that. Just register it and enjoy.

Download Script
Download Script

Comment for suggestions/bugs.

Arc2Google ArcGIS 10


This is a dedication to my smart GIS readers, I decided to do something simple and easy to setup, and intuitive to use and make your life much easier for free.

I called it Arc2GoogleThis tool is not sponsored by or affiliated with Arc2Earth

This tool combines ArcMap with Google Maps And Google Earth.
When you activate the tool it open a dockable window inside ArcMap and show you the current Extent on the Map in Google Maps or Earth, it get refreshed whenever you change the view in GIS too.


Just a reminder that I have also updated the tool to support Yahoo and Bing Maps as well.


Watch a Video demonstration of the tool

Or Let the pictures speak.


Enjoy























Note: In Windows Server, Vista and 7 you should run the installation as Administrator, to do that you have to follow the following:

Copy Arc2Google.msi to C:\

Open notepad and write the following


Save As and select All files and type the name of the file as installarc2google.bat


You should have something like below



Right click and run as administrator





Then if you couldn't get the Toolbar in Arcmap, try running ArcMap as Administrator.




Shoot me and email for any help






Download Script
Download Script

ESRI Geodatabase Downgrade Tool


Most of you must have at least few 9.x (9.2, 9.3, 9.3.1 hopefully no 9.1) while your main production ESRI geodatabase is in 10.x you must face it frustrating that your 10 data won't work on 9.x machines.


Here is a simple tool to use to "Downgrade" any geodatabase to a 9.x version.




Open ArcCatalog


Navigate to the tool.




Double click on Downgrade GDB tool.




Select your 10 gdb




Enter the information
The output will be in the same folder




The result will be the same as your selected gdb plus a 9x suffix.




Enjoy.



Download Script
Download Script

Batch Compact ESRI Map Document (MXD)


Do you have lots of Map Documents with huge sizes?

Compact them all with one click with this tool to more than 60% of their actual size.

Download Compact MXD Tool.

1) Just open an empty ArcMap session
2) Run CompactMXD.exe
3) Select the path where your Map Documents are located.
4) Click Compact.







Download Script
Download Script



I have implemented this guy's idea .



Find Duplicate Attributes in an ESRI Geodatabase


I snapped this idea from ideas.arcgis.com,
I have been looking for a GP tool that can be used to find and list duplicate attribute values in an attribute table since ArcGIS 9.3.  I was able to find a SQL script for this purpose in the GDB Management Island at the 2012 UC, but I would have to Remote Desktop into another machine to run this process.  
If the duplicate ID values can be found and listed using a GP tool, that would be helpful in my organization's workflow process. 

Until ESRI implements this, here is a quick script I wrote for you guys to do just that.


  • Open ArcMap
  • Go to customize
  • Go to Commands 
  • Scroll until UI Controls
  • Click NeW UIControl and select button
  • Drag the new button anywhere in the toolbars
  • Right click on the new button and click view source (make sure you are still in customize mode)
  • Paste the code and run,
  • you must first select the layer you want to find the duplicates in and then click the button, there you will be prompted to type-in the field name..




















Download Script
Download Script