How to (programmatically) figure out the path of the current ArcMap document with VBA

StackOverflow https://stackoverflow.com/questions/2675898

  •  28-09-2019
  •  | 
  •  

Pergunta

I would like a Visual Basic for Application Function which shows the path of the current document.

For example if ArcMap is displaying map.mxd I need to display its path.

I found only some examples for querying the path of the datasources of the displayed layers.

Foi útil?

Solução

Use this:

Dim DocAbsPath As String
DocAbsPath = Application.Templates.Item(Application.Templates.Count - 1)

Taken from this thread.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top