Access to Project without opening in Pro UI

206
2
04-04-2019 03:22 PM
AdamDavis
Occasional Contributor

Hi,

I would like to access a Pro Project programmatically without first opening it in the UI. Is this possible?

I can see with CIM that there is a CIMGISProject object but it is unclear how to obtain that object from a path.

Back in ArcObjects we could open and manipulate an mxd without it being opened in the UI.

Thanks,

Adam

0 Kudos
2 Replies
Wolf
by Esri Regular Contributor
Esri Regular Contributor

Hi Adam, 

 The SDK doesn't provide any means to open and manipulate a project without running ArcGIS Pro, however, you can unzip the project file (manually or programmatically) and examine its content.  The content is in XML format including the CIMGISProject.

- Wolf

0 Kudos
AdamDavis
Occasional Contributor

Hi Wolf,

Thanks so much for your reply and that is very interesting information which may give me a way of accessing the details I need if there is no other option.

However, I apologise for not correctly wording my question. I want to be able to access a "side" project whilst in ArcGIS Pro without visually opening the project.

In the SDK I can only see Project.AsyncOpen(path) which opens/loads the project within the Pro User Interface. Is there a way from within the ArcGIS Pro SDK to open a project without it opening/loading in the UI?

Akin to ArcObjects

IMapDocument mxdDocument = new MapDocumentClass();

mxdDocument.Open(path);

IGraphicsContainer graphicsContainer = (IGraphicsContainer)mxdDocument.PageLayout;

//Do something

mxdDocument.Close();

Thanks,


Adam

0 Kudos