<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to set &amp;quot;map description&amp;quot; parameter in arcpy.PackageMap_management ? in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441757#M34600</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;The input layer must have a description in order for the tool to execute. To add a description, right-click the layer, click Properties, and enter a description&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;from the &lt;A href="http://desktop.arcgis.com/en/arcmap/latest/tools/data-management-toolbox/package-map.htm"&gt;help topic&lt;/A&gt;&amp;nbsp;which means you need to set it.&amp;nbsp; Perhaps you can set it via code from within the &lt;A href="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-mapping/layer-class.htm"&gt;Layer section&lt;/A&gt;, there is the property there you are looking for&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 03 Feb 2017 03:25:32 GMT</pubDate>
    <dc:creator>DanPatterson_Retired</dc:creator>
    <dc:date>2017-02-03T03:25:32Z</dc:date>
    <item>
      <title>How to set "map description" parameter in arcpy.PackageMap_management ?</title>
      <link>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441756#M34599</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I recently started using arcpy to handle batch tasks for arcgis. I am trying to run the &lt;STRONG style="border: 0px;"&gt;arcpy packagemap_management&lt;/STRONG&gt; tool to batch export a bunch of mxds inside a folder.&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;This is what I am running now:&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;-----------------------------------&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;&lt;STRONG style="border: 0px;"&gt;&amp;gt;&amp;gt;&amp;gt; import os&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="border: 0px;"&gt;import arcpy&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;&lt;STRONG style="border: 0px;"&gt;arcpy.env.overwriteOutput = True&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="border: 0px;"&gt;arcpy.env.workspace = "C:\ABC\DirectoryToMxd"&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;&lt;STRONG style="border: 0px;"&gt;for mxd in arcpy.ListFiles("*.mxd"):&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="border: 0px;"&gt;print ("Packaging: {0}".format(mxd))&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="border: 0px;"&gt;arcpy.PackageMap_management(mxd, os.path.splitext(mxd)[0] + '.mpk', "PRESERVE", "CONVERT_ARCSDE", "#", "ALL")&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;&lt;BR /&gt;&lt;STRONG style="border: 0px;"&gt;Packaging: Test.mxd&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="border: 0px;"&gt;Runtime error Traceback (most recent call last): File "&amp;lt;string&amp;gt;", line 9, in &amp;lt;module&amp;gt; File "c:\program files (x86)\arcgis\desktop10.3\arcpy\arcpy\management.py", line 8197, in PackageMap raise e ExecuteError: #ERROR 001117: Map description property must be set Failed to execute (PackageMap).&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;-------------------------------&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;From the error , it seems the code is working but due to the mandatory requirement for map description during mpk export ,it is throwing an error. I checked geonet doc and did not find any parameter to set "description". It only supports summary and tags through command line.&amp;nbsp;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; font-weight: normal;"&gt;Can someone please help me fix this? Is there a hidden parameter I can use to set the map description for all the exports?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Feb 2017 03:07:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441756#M34599</guid>
      <dc:creator>KaustavChaudhury1</dc:creator>
      <dc:date>2017-02-03T03:07:58Z</dc:date>
    </item>
    <item>
      <title>Re: How to set "map description" parameter in arcpy.PackageMap_management ?</title>
      <link>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441757#M34600</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;The input layer must have a description in order for the tool to execute. To add a description, right-click the layer, click Properties, and enter a description&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;from the &lt;A href="http://desktop.arcgis.com/en/arcmap/latest/tools/data-management-toolbox/package-map.htm"&gt;help topic&lt;/A&gt;&amp;nbsp;which means you need to set it.&amp;nbsp; Perhaps you can set it via code from within the &lt;A href="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-mapping/layer-class.htm"&gt;Layer section&lt;/A&gt;, there is the property there you are looking for&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Feb 2017 03:25:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441757#M34600</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-02-03T03:25:32Z</dc:date>
    </item>
    <item>
      <title>Re: How to set "map description" parameter in arcpy.PackageMap_management ?</title>
      <link>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441758#M34601</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Dan,&lt;/P&gt;&lt;P&gt;Good to hear from you!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you please elaborate your suggestion? If you meant to check the map_management help topic, I already did that. And I didnt find any option/parameter for defining the map description via python code.&lt;/P&gt;&lt;P&gt;Basically I am trying to set the below fields via command line during mpk creation:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/314054_pastedImage_1.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Feb 2017 03:29:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441758#M34601</guid>
      <dc:creator>KaustavChaudhury1</dc:creator>
      <dc:date>2017-02-03T03:29:24Z</dc:date>
    </item>
    <item>
      <title>Re: How to set "map description" parameter in arcpy.PackageMap_management ?</title>
      <link>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441759#M34602</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;in the link on layers, under properties&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;description&lt;/STRONG&gt;&lt;BR /&gt;(&lt;EM&gt;Read and Write&lt;/EM&gt;)&lt;BR /&gt;Provides the ability to either get or set the layer's description information. Not all layers support the description property (for example, topology layers), so it is good practice to test for this ahead of time using the supports method.&lt;BR /&gt;String&lt;/P&gt;&lt;P&gt;Which means you can get and/or set it with arcpy&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To clarify.... the layers need to have their description set in order for them to be packaged... at least that is my reading of the packagemap help and the layer help&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Feb 2017 04:33:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441759#M34602</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-02-03T04:33:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to set "map description" parameter in arcpy.PackageMap_management ?</title>
      <link>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441760#M34603</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This description seems to be for individual layers. I am looking for "Map Package" property: Description field.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please have a look at the screenshot I shared in my earlier comment.&lt;/P&gt;&lt;P&gt;&lt;IMG class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/314081_pastedImage_1.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Feb 2017 04:37:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441760#M34603</guid>
      <dc:creator>KaustavChaudhury1</dc:creator>
      <dc:date>2017-02-03T04:37:56Z</dc:date>
    </item>
    <item>
      <title>Re: How to set "map description" parameter in arcpy.PackageMap_management ?</title>
      <link>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441761#M34604</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A class="link-titled" href="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-mapping/mapdocument-class.htm" title="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-mapping/mapdocument-class.htm"&gt;MapDocument—Help | ArcGIS Desktop&lt;/A&gt;&amp;nbsp; I guess I am reading the error wrong then, since the error noted in step 6&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="http://desktop.arcgis.com/en/arcmap/latest/map/working-with-arcmap/creating-a-map-package.htm" title="http://desktop.arcgis.com/en/arcmap/latest/map/working-with-arcmap/creating-a-map-package.htm"&gt;Creating a map package—Help | ArcGIS Desktop&lt;/A&gt;&amp;nbsp;had to do with the unresolved mapdocument not having the correct requirements, which can be set at the mapdocument level.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The package map code script which you posted doesn't even show the need to provide a map package description.&lt;/P&gt;&lt;P&gt;I am also assuming that you code example just lacks proper indentation because of not using the syntax highlighter. &amp;nbsp;You might want to check that the arcpy.env.workspace path should be set to a raw format string ( ie r"c:\somefolder") but I doubt that these would have thrown that error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I you get this issue straightened out, please post back&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Feb 2017 09:55:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441761#M34604</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-02-03T09:55:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to set "map description" parameter in arcpy.PackageMap_management ?</title>
      <link>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441762#M34605</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am able to perform a simple "print" statement for all the mxd inside that folder and getting desired results. So I am sure it is not an python indentation problem. the piece of code is able to read through the contents inside the folder and not throwing any error.&amp;nbsp;&lt;/P&gt;&lt;P&gt;The issue is tied to the mandatory requirement for "package map" description field. But there is no parameter associated with&amp;nbsp;&lt;STRONG style="background-color: #ffffff; border: 0px; font-weight: bold;"&gt;arcpy packagemap_management &lt;/STRONG&gt;which I can fill through command line.&lt;/P&gt;&lt;P&gt;The error clearly shows that the description is necessary ,but it does not support pushing that value through the above code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="border: 0px; font-weight: bold;"&gt;Runtime error Traceback (most recent call last): File "&amp;lt;string&amp;gt;", line 9, in &amp;lt;module&amp;gt; File "c:\program files (x86)\arcgis\desktop10.3\arcpy\arcpy\management.py", line 8197, in PackageMap raise e ExecuteError: #ERROR 001117: Map description property must be set Failed to execute (PackageMap).&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now since I want to iterate the job for all the mxds inside the folder, how do I bypass that requirement. Or rather set it via arcpy using the above code for all the mxds.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Feb 2017 16:37:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-set-quot-map-description-quot-parameter-in/m-p/441762#M34605</guid>
      <dc:creator>KaustavChaudhury1</dc:creator>
      <dc:date>2017-02-03T16:37:42Z</dc:date>
    </item>
  </channel>
</rss>

