Hi All,
I am having a problem with using a variable as the output cell size for the Feature to Raster tool in Model Builder. I have tried using both a raster layer as the variable, as well as a cell size variable defined as a parameter for the model. So far the only way I can get my output raster to have the correct cell size is to hard code it into the tool dialogue, which I am trying to avoid. I have tried about every possible thing I can think of including changing the environment settings and nothing is working. Please help!
Daniel
I know this is a VERY OLD post, but this solution might be useful for someone coming across this error in the future:
Whenever you use the Calculate Value/Get Field Value Utility in Model Builder, you have to make sure that the output variable type is the same as the one required for the next tool in your model. For example, I am running the Get Field Value tool on a Summary Statistics Table to retrieve the Minimum value of my input data.
Then, I am using this value as the cell size for an output raster. By going to the documentation for a tool, you can find out the data type required for each of the parameter, which for my tool (Point to Raster) is Analysis cell size.
I set the output type to this (on the Data Type field of the Utility I am using), and now I can connect the tools and choose Cell size as the input parameter.
The Calculate Value tool is very helpful for not only doing calculations, but casting strings to a data type needed by the tool. Great comment.
How can the cell size value be inserted into a specific field in the attribute table of a raster, as shown in the screenshot below?