Select to view content in your preferred language

Check aprx metadata on project open

198
1
4 weeks ago
MichaelKohler
Frequent Contributor

Hi,

I have a Desktop Addin that will check the properties of an mxd when it's opened to see if the mxd can be used for the addin. No tricky logic, just read the Map Document Properties and see if a keyword is present in the Credits. If it is present, then the addin will "load" the mxd and create all the necessary references to layers and what not needed to run the tools.

While porting the Desktop addin to Pro, I am having a terrible time trying to replicate this with Pro 3.5 SDK. I've researched this and some stuff says it is possible but the code never works and others say that it's not possible. 

pro_metadata_for_pam.png

 Is there a way to read the tags?

0 Kudos
1 Reply
MichaelKohler
Frequent Contributor

Decided that an easier way to go would be to subscribe to the

ProjectOpenedEvent.Subscribe(OnProjectOpened);

Then I can test to see if the layers are present and then "load" the data into the addin.

 

0 Kudos