Error in executing grid expression

1742
3
11-08-2011 04:49 AM
tomwaddington
New Contributor
Can any one help, explain and possible provide a solution as to why this code keeps producing and error. Everything else runs up to this point and every variable is defined.

gp.MultiOutputMapAlgebra_sa("H:\Internship_Tom_Waddington\New_code/forest_b2grd = CON('H:\Internship_Tom_Waddington\New_code/forest_b1grd > 0,H:\Internship_Tom_Waddington\New_code/dem_resample')")


Traceback (most recent call last):
  File "H:\Internship_Tom_Waddington\New_code\new_code.py", line 86, in <module>
    gp.MultiOutputMapAlgebra_sa("H:\Internship_Tom_Waddington\New_code/forest_b2grd = CON('H:\Internship_Tom_Waddington\New_code/forest_b1grd > 0,H:\Internship_Tom_Waddington\New_code/dem_resample')")
ExecuteError: ERROR 010067: Error in executing grid expression.
Failed to execute (MultiOutputMapAlgebra).
Tags (2)
0 Kudos
3 Replies
RaphaelR
Occasional Contributor II
in python you have to specify paths in one of these 3 ways:
r"c:\path"
"c:\\path"
"c:/path"

using "c:\path" won´t work.
0 Kudos
tomwaddington
New Contributor
Even with all the paths the same i.e. C:/path I still keep getting the Error in executing grid expression on the same line of code. Is there anything else that you think may be the cause?
0 Kudos
DuncanHornby
MVP Notable Contributor
Tom,

Don't have a grid file name long than 8 characters.

Duncan
0 Kudos