<?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: Error: Using Search Cursor on XLS File in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56531#M4494</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Just a shot in the dark here, but could the problem be the file extension?&amp;nbsp; Are you sure it is ".xls" and not ".xlsx"?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 20 Feb 2014 11:03:23 GMT</pubDate>
    <dc:creator>JamesCrandall</dc:creator>
    <dc:date>2014-02-20T11:03:23Z</dc:date>
    <item>
      <title>Error: Using Search Cursor on XLS File</title>
      <link>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56530#M4493</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am trying to cursor search through a .xls file using &lt;/SPAN&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;arcpy.SearchCursor&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My code is this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
xls = r"\\spatialfiles.work\Local\scripts\python\Excel\Report.xls\'Dataset selection$'"

for row in arcpy.SearchCursor(xls):
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print row.getValue("Layer")&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm baffled. Yesterday this code worked fine. Today I am getting an error:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;IOError: "\\spatialfiles.work\Local\scripts\python\Excel\Report.xls\'Dataset selection$'"&lt;BR /&gt;does not exist&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The xls file does exist. I can navigate to it in ArcCataloge without issue and view the table. The path is correct because I copied and pasted it right out of Catalogue. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Can anyone suggest why this is occuring?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Mike&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Dec 2021 22:09:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56530#M4493</guid>
      <dc:creator>MikeMacRae</dc:creator>
      <dc:date>2021-12-10T22:09:08Z</dc:date>
    </item>
    <item>
      <title>Re: Error: Using Search Cursor on XLS File</title>
      <link>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56531#M4494</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Just a shot in the dark here, but could the problem be the file extension?&amp;nbsp; Are you sure it is ".xls" and not ".xlsx"?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Feb 2014 11:03:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56531#M4494</guid>
      <dc:creator>JamesCrandall</dc:creator>
      <dc:date>2014-02-20T11:03:23Z</dc:date>
    </item>
    <item>
      <title>Re: Error: Using Search Cursor on XLS File</title>
      <link>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56532#M4495</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for checking, but yes. It's .xls. I copied and pasted the path straight from Catalogue.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The other weird anamolay is that, I can write the script through the python shell, line for line adn then it will work. When I do it from the pything window as a script, it throws that same error all the time.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Feb 2014 14:01:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56532#M4495</guid>
      <dc:creator>MikeMacRae</dc:creator>
      <dc:date>2014-02-20T14:01:54Z</dc:date>
    </item>
    <item>
      <title>Re: Error: Using Search Cursor on XLS File</title>
      <link>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56533#M4496</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Thanks for checking, but yes. It's .xls. I copied and pasted the path straight from Catalogue.&lt;BR /&gt;&lt;BR /&gt;The other weird anamolay is that, I can write the script through the python shell, line for line adn then it will work. When I do it from the pything window as a script, it throws that same error all the time.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Maybe related to 64-bit processing?&amp;nbsp; Have a look at the .xls/.xlsx reference in this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/main/10.1/index.html#//002100000040000000"&gt;http://resources.arcgis.com/en/help/main/10.1/index.html#//002100000040000000&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Sorry for such abstract answers, I find this topic entirely confusing and have not had to deal with these issues as of yet.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Feb 2014 14:41:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56533#M4496</guid>
      <dc:creator>JamesCrandall</dc:creator>
      <dc:date>2014-02-20T14:41:02Z</dc:date>
    </item>
    <item>
      <title>Re: Error: Using Search Cursor on XLS File</title>
      <link>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56534#M4497</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I was having the exact same issue yesterday.&amp;nbsp; I was using&amp;nbsp; I kind of resolved it, but still don't quite know what's going on.&amp;nbsp; One thing I noticed was that while I was in ArcMap and looking at the excel files in the ArcCatalog window, whenever I was getting the error I was also not able to expand the xls file to show the individual sheets within it.&amp;nbsp; I would get a "dataset doesn't exist or is not supported" type of error.&amp;nbsp; Basically, I'm thinking that it comes down to some sort of permissions issue.&amp;nbsp; I was able to get things to work by alternately closing the python shell/IDLE as well as reopening ArcMap.&amp;nbsp; Also, refreshing the folder in the catalog window helps.&amp;nbsp; Eventually I was able to expand the file in the catalogue window, and also run the scripts.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Not sure if this is helpful, but good luck!&amp;nbsp; It may be worth importing the table to a geodatabase, and using it from there.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Feb 2014 14:44:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56534#M4497</guid>
      <dc:creator>AdamCox1</dc:creator>
      <dc:date>2014-02-20T14:44:49Z</dc:date>
    </item>
    <item>
      <title>Re: Error: Using Search Cursor on XLS File</title>
      <link>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56535#M4498</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I decided to try the code in Ecvlsipe instead of IDLE. It works there, so I'm lead to believe thatit's an IDLE issue. I've had these issues before, so I think I'm done with using IDLE.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Feb 2014 17:59:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/error-using-search-cursor-on-xls-file/m-p/56535#M4498</guid>
      <dc:creator>MikeMacRae</dc:creator>
      <dc:date>2014-02-20T17:59:52Z</dc:date>
    </item>
  </channel>
</rss>

