Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I have a question which has been bothering me for ages. When I do a batch command in ArcGIS e.g. Projection transformation the batch dialog has a field for the "new file name".

The default Directory is however always the same folder as the original files. If I want to change the Directory but keep the old names, there is a strange syntax which I can use....something like %n%...but I would still have to copy and paste the complete path to the new folder.

Why is there not the option to simply pick a new folder and viola!?! or is there an easier way than having to search the forums for this syntax every 2 months when I need to run the batch command?

Thanks for any help,


share|improve this question

1 Answer 1

In addition to running tool in batch mode by right clicking it and choosing Batch... you can also write a small python script. There you can run your desired tool in a loop with your specific logic of providing output location. i.e. by setting output folder for shp or output GDB for featureclasses or even modifying featureclass name with some counter or whatever.

If you want "simply pick a new folder and viola" then for Project (Data Management) tool there are already prepared script in ArcToolbox: Data Management Tools\Projections and Transformations\Feature\Batch Project

You can right click it, choose Edit... and then use that Python script as an example for writing your own one for different tools.

share|improve this answer
ok Thanks.....Does anyone know this "syntax" well that I mentioned?...with the %n% variable? Maybe there is a way to set a new directory with that...then I don´t have to bother with Python. The problem is that it is for other ArcGIS users who rarely do geoprocessing, so using python is a bit too applied! –  Robert Buckley May 14 '12 at 8:22
You can prepare script for them and they can use it as a common tool. Like you can use Data Management Tools\Projections and Transformations\Feature\Batch Project and don't even know that it is python script inside. –  Alex Markov May 14 '12 at 8:40

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.