Convert MPK to MMPK

338
5
11-16-2020 05:44 AM
YaronAvraham
New Contributor III

Hi

I Need to convert existing MPK file to MMPK.

when i try to importDocument i get OSError.

this is the script:

p = arcpy.mp.ArcGISProject(r"path to aprx")
p.importDocument(r"Path to mpk")

 

is this correct?

 

Edit: I've tried using CreateMobileMapPackage directly, it worked but only part of the mpk was converted to mmpk with the script:

arcpy.management.CreateMobileMapPackage([mpkFileInputPath], mmpkOutputFilePath)

whats the right way converting mpk to mmpk?

 

any advice will be appreciated

0 Kudos
5 Replies
DanPatterson
MVP Notable Contributor

Under the Useage section of create-mobile-map-package , there are some listed limitations.  Do any apply to you?


... sort of retired...
0 Kudos
YaronAvraham
New Contributor III

well after few tries in arcgis pro, i found the problem is the default extent, 

even when i configure the extent as Union of inputs it wont fix the problem, 

the only thing that helped is configuring the extent manually,

any idea why?

0 Kudos
DanPatterson
MVP Notable Contributor

Were the data all in the same coordinate system to begin with?


... sort of retired...
0 Kudos
YaronAvraham
New Contributor III

yep, its  mpk with 12 layers of a city, with WGS 1984 coordinate system

0 Kudos
DanPatterson
MVP Notable Contributor

No reported bugs... one of life's mysteries then


... sort of retired...
0 Kudos