I have developed the python script for Compress,Rebuild Indexes and Analyze datasets. For that I am getting the list of feature classes using arcpy.ListFeatureclasses() function.It is working in ArcGIS10.2.1 (Python IDLE 2.7.5).It gives propoer results.Th

1350
4
08-06-2016 09:40 PM
veeraa
by
New Contributor

I have developed the python script for Compress ,Rebuild Indexes and Analyze datasets. For that I am getting the list of feature classes using arcpy.ListFeatureclasses() function.It is working in ArcGIS10.2.1 (Python IDLE 2.7.5).It gives propoer results.The same code was executed in ArcGIS10.3.1(Python IDLE 2.7.8).It was not executed and not giving the results.Please help me on this.

Tags (3)
0 Kudos
4 Replies
DanPatterson_Retired
MVP Esteemed Contributor

Since you haven't included the error message or the code that failed, your only option is to go through the changelogs that occurred in Arcmap between version 10.2 and 10.3 and also look at the version changes in python.  These can be found on my blog

The ...py... links

Alternately, you can provide the code and error message and details of the environments used during the script execution.

veeraa
by
New Contributor

Hi Patterson,

Sorry for the late response. It not gives any error. After the  arcpy.ListFeatureclasses() line the code was not executed. I am using the following the code.

dataList = arcpy.ListTables() + arcpy.ListFeatureClasses() + arcpy.ListRasters()

Please suggest any alternate to get the list of feature classes and how to stop the views while rebuilding.

0 Kudos
DanPatterson_Retired
MVP Esteemed Contributor

you can't add all those things together, they are different objects...

A single line of code isn't going to help, especially since you can't check that line out... oh yes... print statements would help you dissect the issue

0 Kudos
WesMiller
Regular Contributor III

Have tried putting some print statements in?

print arcpy.env.workspace

print dataList

ListFeatureClasses—Help | ArcGIS for Desktop

0 Kudos