<?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: layer.exportToPDF(filePath) OSError on _arc_object.exportToPDF in ArcGIS API for Python Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-python-questions/layer-exporttopdf-filepath-oserror-on-arc-object/m-p/1014920#M5397</link>
    <description>&lt;P&gt;nope &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt; i use os path join to join up filepath. Furthermore it works with my user account. Just not a service account&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also see this post by Igor that had the exact same error.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/t5/arcgis-web-appbuilder-questions/cannot-print-very-frustrating-problem/td-p/732644/page/6" target="_blank"&gt;https://community.esri.com/t5/arcgis-web-appbuilder-questions/cannot-print-very-frustrating-problem/td-p/732644/page/6&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 07 Jan 2021 23:10:37 GMT</pubDate>
    <dc:creator>VictorTey</dc:creator>
    <dc:date>2021-01-07T23:10:37Z</dc:date>
    <item>
      <title>layer.exportToPDF(filePath) OSError on _arc_object.exportToPDF</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/layer-exporttopdf-filepath-oserror-on-arc-object/m-p/1014673#M5393</link>
      <description>&lt;P&gt;Hi, I have a piece of code that ran fine as a user however once it runs as a service account, I get the following error.&amp;nbsp; Can anyone kindly assist?&lt;/P&gt;&lt;LI-CODE lang="python"&gt; File "E:\GeoprocessingWorkforce\PROD2_WORKSPACE\dev_phase2\report_handler.py", line 67, in PrintReport
    lyt.exportToPDF(filePath)
  File "C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\utils.py", line 191, in fn_
    return fn(*args, **kw)
  File "C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\_mp.py", line 1161, in exportToPDF
    return convertArcObjectToPythonObject(self.c(*gp_fixargs((out_pdf, resolution, image_quality, compress_vector_graphics, image_compression, embed_fonts, layers_attributes, georef_info, jpeg_compression_quality, clip_to_elements, output_as_image, embed_color_profile), True)))
OSError: E:\pdfs\abc.pdf&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Jan 2021 16:00:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/layer-exporttopdf-filepath-oserror-on-arc-object/m-p/1014673#M5393</guid>
      <dc:creator>VictorTey</dc:creator>
      <dc:date>2021-01-07T16:00:38Z</dc:date>
    </item>
    <item>
      <title>Re: layer.exportToPDF(filePath) OSError on _arc_object.exportToPDF</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/layer-exporttopdf-filepath-oserror-on-arc-object/m-p/1014676#M5394</link>
      <description>&lt;P&gt;Just wondering if that is the actual output file name, because if python is involved, the lack of raw encoding of the name will cause issues&lt;/P&gt;&lt;LI-CODE lang="python"&gt;p ="E:\pdfs\abc.pdf"   # you should use r"E:\pdfs\abc.pdf"
print(p)
E:\pdfsbc.pdf&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 07 Jan 2021 16:06:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/layer-exporttopdf-filepath-oserror-on-arc-object/m-p/1014676#M5394</guid>
      <dc:creator>DanPatterson</dc:creator>
      <dc:date>2021-01-07T16:06:58Z</dc:date>
    </item>
    <item>
      <title>Re: layer.exportToPDF(filePath) OSError on _arc_object.exportToPDF</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/layer-exporttopdf-filepath-oserror-on-arc-object/m-p/1014920#M5397</link>
      <description>&lt;P&gt;nope &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt; i use os path join to join up filepath. Furthermore it works with my user account. Just not a service account&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also see this post by Igor that had the exact same error.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/t5/arcgis-web-appbuilder-questions/cannot-print-very-frustrating-problem/td-p/732644/page/6" target="_blank"&gt;https://community.esri.com/t5/arcgis-web-appbuilder-questions/cannot-print-very-frustrating-problem/td-p/732644/page/6&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Jan 2021 23:10:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/layer-exporttopdf-filepath-oserror-on-arc-object/m-p/1014920#M5397</guid>
      <dc:creator>VictorTey</dc:creator>
      <dc:date>2021-01-07T23:10:37Z</dc:date>
    </item>
    <item>
      <title>Re: layer.exportToPDF(filePath) OSError on _arc_object.exportToPDF</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/layer-exporttopdf-filepath-oserror-on-arc-object/m-p/1014948#M5398</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/394656"&gt;@VictorTey&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This has been logged as a bug in ArcGIS Enterprise 10.8.1:&lt;/P&gt;&lt;P&gt;&lt;A href="https://support.esri.com/en/bugs/nimbus/QlVHLTAwMDEzMzMxNw==" target="_blank"&gt;https://support.esri.com/en/bugs/nimbus/QlVHLTAwMDEzMzMxNw==&lt;/A&gt;&lt;/P&gt;&lt;H2&gt;Alternate Solution&lt;/H2&gt;&lt;P&gt;Find the patch in the following link,&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://support.esri.com/en/download/7834" target="_blank" rel="noopener"&gt;https://support.esri.com/en/download/7834&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;&lt;P&gt;Mehdi&lt;/P&gt;</description>
      <pubDate>Fri, 08 Jan 2021 01:39:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/layer-exporttopdf-filepath-oserror-on-arc-object/m-p/1014948#M5398</guid>
      <dc:creator>MehdiPira1</dc:creator>
      <dc:date>2021-01-08T01:39:40Z</dc:date>
    </item>
  </channel>
</rss>

