Does ArcGISProject.ImportDocument() satisfy your needs? It allows you to import mapx, pagx and more into a project? We also support exporting to these formats.
Or do you want to be able to connect to a pagx or mapx and repair datasources directly on those? A work around would be to importDocument into a project, change datasources and then export back to the appropriate X file.
Jeff - arcpy.mp and Layout teams.
Given you can use importDocument(path to mapx), change data sources, then export back to mapx, this lessens the priority of creating additional classes and members given a fair amount of other planned development work.
If the above workflow does NOT work for you, please describe in detail you scenario and we could reconsider.
Jeff - Layout and arcpy.mp teams
Thanks @matt_g_g . If you write your script to work out of process along with a reference to a "blank.aprx", for example, it all would happen in memory and the application would not even be opened. To work with a mapx or a pagx file, you need the application (internal logic) to read the files in order for them to be modified. Even if you wanted to use Python CIM access to modify the JSON structure, you still need the application. Those X files are text files but I would never recommend modifying those in a text editor. If you have specific issues with import/export x-files, I'd like to know the limitations.
Jeff - arcpy.mp and Layout SDK teams
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.