Set default geodatabase per user environment

2690
7
10-20-2014 10:35 AM
Highlighted
New Contributor III

Our shop uses a common map document for our production work. This map has many layers loaded from many locations, along with custom symbolizations, drawing scale settings, etc. Periodically, one person goes through this map document to implement updates to this MXD, that then become part of the department's working map.

 

The problem is that the saved map document has that one person's setting for the default geodatabase - which means when that MXD is rolled out, everyone in the department is using that person's default geodatabase. As you can imagine, it's a networked environment with roaming profiles so users' home directories are on servers.

 

It would be great (and simple) to have the default geodatabase specified using the syntax of environment strings, so that when each user picks up an updated production map, they don't have to remember to reset their default geodatabase to their own home directory.

 

Can the Default Geodatabase be specified, and saved in the MXD, as (for example) "%LOCALAPPDATA%\ArcGIS" ?  Or whatever environment string substitution makes sense for a local (or enterprise) group...

7 Replies
Highlighted
New Contributor III

I believe you can set the Default GDB also at the MXD level.

- Open the MXD

- File > Map Document Properties

- Set the Default GDB --> in your case a server location.

As long as everybody has access to that server, all should be able to connect.

- Juul

Highlighted
New Contributor III

Yes, one can set the default GDB in the Map Document Properties. I don't want to have to create an MXD for each user with their Default GDB setting. And I don't want to have to ask each user to set their default GDB when they take a copy of the production MXD. And I'd rather they not all use the same geodatabase on the network, when it's only used for is temporary storage of local geoprocessing tasks. It might reside on their local machine, or in their local profile. In either case it would be a different path for each user and I don't want to make copies of the MXD configured for each user. And I don't want to ask each user to make local customizations to the MXD when they take a copy of the production MXD off the server.

Reply
0 Kudos
Highlighted
New Contributor III

Is your MyDocuments folder redirected to a server location per user?

Would this article be any help?

40332 - Set the default Home folder and geodatabase location for new map documents

When I open an mxd in Arcmap 10.2.1 from a server location the Default GDB automatically defaults to the MyDocuments directory. This mxd was previously set to another default gdb on a different system. The same goes for the Environment settings of Workspace and Scratch. I tried setting the Map Document properties to a %Temp% variable which did not persist on my other machine. It just changed it to my local default.

- Juul

Highlighted
New Contributor III

Yes, that works for *New* map documents. But I need staff to pick up an *Existing* map document - one that's made by a GIS person - and have the default geodatabase for it switch over to that staff person's default geodatabase without the staff person having to remember to manually switch it over themself.

Reply
0 Kudos
Highlighted
New Contributor III

I tried the registry edit as described in the article 40332, as linked to. As others on that page have noted, it does not cause an existing map document to switch its default geodatabase to the specified location.

Reply
0 Kudos
Highlighted
Occasional Contributor

I am having the same problem.  Many of my MXDs no longer have the "default" I set them to, but have reset themselves to the default.gdb in my home directory.

Reply
0 Kudos
Highlighted
Occasional Contributor

Yes, it seems odd that there is access to every other property but the default GDB through arcpy.mapping. You dan read and set any other property but this one it seems.

MapDocument—Help | ArcGIS for Desktop 

Reply
0 Kudos