<?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: using python+arcpy within Eclipse in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/using-python-arcpy-within-eclipse/m-p/45218#M3561</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Does it fail if you use the full path to your arcmap document?&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Oh, that's interesting...it DOES work with the full path:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;mxd = arcpy.mapping.MapDocument("D:/delta/GIS/DSM2/DSM2_Network.mxd")&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;But from IDLE this works:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;import arcpy, os, time
from arcpy.mapping import *
workspace = "D:/delta/GIS/DSM2"
mxd = arcpy.mapping.MapDocument("DSM2_Network.mxd")
&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;Why not from Eclipse, I wonder?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 10 Dec 2021 21:45:24 GMT</pubDate>
    <dc:creator>RalphFinch</dc:creator>
    <dc:date>2021-12-10T21:45:24Z</dc:date>
    <item>
      <title>using python+arcpy within Eclipse</title>
      <link>https://community.esri.com/t5/python-questions/using-python-arcpy-within-eclipse/m-p/45216#M3559</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;ArcGIS 10SP2, Win7x64.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I use the Eclipse IDE for other work, and would like to use it with arcpy. But I get this error:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;File "C:\Program Files (x86)\ArcGIS\Desktop10.0\arcpy\arcpy\arcobjects\mixins.py", line 443, in __init__&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; assert (os.path.isfile(mxd) or (mxd.lower() == "current")), gp.getIDMessage(89004, "Invalid MXD filename")&lt;BR /&gt;AssertionError: Invalid MXD filename.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;the offending code line is: &lt;/SPAN&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;mxd = arcpy.mapping.MapDocument("DSM2_Network.mxd")&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;This works perfectly well within, say, IDLE.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My Python interpreter libraries are as follows:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;IMG src="http://dl.dropbox.com/u/8821142/ScreenShot001.png" /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any ideas what I've set wrong within Eclipse?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Aug 2011 16:09:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/using-python-arcpy-within-eclipse/m-p/45216#M3559</guid>
      <dc:creator>RalphFinch</dc:creator>
      <dc:date>2011-08-19T16:09:34Z</dc:date>
    </item>
    <item>
      <title>Re: using python+arcpy within Eclipse</title>
      <link>https://community.esri.com/t5/python-questions/using-python-arcpy-within-eclipse/m-p/45217#M3560</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Does it fail if you use the full path to your arcmap document?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Aug 2011 16:40:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/using-python-arcpy-within-eclipse/m-p/45217#M3560</guid>
      <dc:creator>AndrewChapkowski</dc:creator>
      <dc:date>2011-08-19T16:40:53Z</dc:date>
    </item>
    <item>
      <title>Re: using python+arcpy within Eclipse</title>
      <link>https://community.esri.com/t5/python-questions/using-python-arcpy-within-eclipse/m-p/45218#M3561</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Does it fail if you use the full path to your arcmap document?&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Oh, that's interesting...it DOES work with the full path:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;mxd = arcpy.mapping.MapDocument("D:/delta/GIS/DSM2/DSM2_Network.mxd")&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;But from IDLE this works:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;import arcpy, os, time
from arcpy.mapping import *
workspace = "D:/delta/GIS/DSM2"
mxd = arcpy.mapping.MapDocument("DSM2_Network.mxd")
&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;Why not from Eclipse, I wonder?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Dec 2021 21:45:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/using-python-arcpy-within-eclipse/m-p/45218#M3561</guid>
      <dc:creator>RalphFinch</dc:creator>
      <dc:date>2021-12-10T21:45:24Z</dc:date>
    </item>
    <item>
      <title>Re: using python+arcpy within Eclipse</title>
      <link>https://community.esri.com/t5/python-questions/using-python-arcpy-within-eclipse/m-p/45219#M3562</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I get the error for both editors.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you look at the MapDocument object, the path parameter states the following:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;&lt;BR /&gt;A string that includes the full path and file name of an existing map document (.mxd) or a string that contains the keyword CURRENT.&lt;BR /&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;I do not believe this object honors the environmental workspace parameter, and unless run from ArcMap, the full path should always be used for the map document.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You can find more information here about &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#/MapDocument/00s30000000n000000/"&gt;MapDocument&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Aug 2011 09:24:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/using-python-arcpy-within-eclipse/m-p/45219#M3562</guid>
      <dc:creator>AndrewChapkowski</dc:creator>
      <dc:date>2011-08-22T09:24:15Z</dc:date>
    </item>
  </channel>
</rss>

