Hi:
I am working at putting a script together using Pythonwin that will work with input data contained in either shapefiles or a PGDb. Script is setup to output to either a folder or a PGb. I have everything working with shapefiles... now just debugging to get working with outputting to a PGDb. Script is getting hung up on ExtractValuesToPoints (runs fine on first instance of ExtractValuesToPoints, fails on second). Running ArcGIS 10.1, SP1, advanced license over Win7. I have imported arcpy.sa and have spatial analyst checked out... script checks license level: ArcInfo.
Error generated through Pythonwin:
Traceback (most recent call last):
File "<interactive input>", line 1, in <module>
File "C:\Program Files (x86)\ArcGIS\Desktop10.1\arcpy\arcpy\sa\Functions.py", line 1311, in ExtractValuesToPoints
add_attributes)
File "C:\Program Files (x86)\ArcGIS\Desktop10.1\arcpy\arcpy\sa\Utils.py", line 47, in swapper
result = wrapper(*args, **kwargs)
File "C:\Program Files (x86)\ArcGIS\Desktop10.1\arcpy\arcpy\sa\Functions.py", line 1304, in wrapper
add_attributes)
File "C:\Program Files (x86)\ArcGIS\Desktop10.1\arcpy\arcpy\geoprocessing\_base.py", line 498, in <lambda>
return lambda *args: val(*gp_fixargs(args, True))
ExecuteError: ERROR 999999: Error executing function.
No current record.
Failed to execute (ExtractValuesToPoints).
Details of success/failure in script:
Code for each instance below...
Notes:
ExtractValuesToPoints(pthTemp + "\\paths_pours_nil" + txtOutExt, grdStrLnks, pthTemp + "\\paths_pours_nil2" + txtOutExt, "NONE", "VALUE_ONLY")
ExtractValuesToPoints(pthTemp + "\\pours_all" + txtOutExt, grdFacc1_0, pthTemp + "\\pours_all2" + txtOutExt, "NONE", "VALUE_ONLY")
arcpy.gp.ExtractValuesToPoints_sa("pours_all","E:/a000/temp.mdb/facc1_0","E:/a000/temp.mdb/pours_all999","NONE","VALUE_ONLY")
arcpy.ExtractValuesToPoints_sa("pours_all","E:/a000/temp.mdb/facc1_0","E:/a000/temp.mdb/pours_all999","NONE","VALUE_ONLY")
I can't figure out why the ExtractValuesToPoints process will run in ArcGIS desktop, but not through Pythonwin when using the same data and outputting to the same container?
Any help will be much appreciated!