Ok,
My thoughts were if either your FC or ras list were empty it would fail, so I check those first.. I’d put a print with a count first. This confirms the data is there.. If you put a print after
for shp in fc:
print shp you could watch for errors as you would know the file being processes.
A
for raster in ras:
print ras would tell you which raster is being processed.
Both of these help rule out data issues, as everyone always looks at the code when it might be a simple data issue. No use troubleshooting code if this is the case.
For grins, comment out lines 6 + 7, just write the variables in as text until you get it and running This takes out dumb input errors, like did they use the backslash or forwardslash, python is funny about that..
My next though is why are you checking : if (shp == point and raster == dem):
You already defined them in the above code. Your loops would stop if you ran out of shapes or rasters..
On line 22, dem = ____ should line up under point = ____
Ok, now for the logic error..
Why do you need lines 21 and 22? They are not part of your naming of the output and it will step though all the rasters and shapes in the list..
Bill