ArcGIS Engine栅格计算使用IMapAlgebraOp 接口一直报错如何解决?
如题,ArcGIS Engine栅格计算使用IMapAlgebraOp 接口,出现如图所示错误
代码如下:
IMapAlgebraOp rstcal = new RasterMapAlgebraOpClass();
IRasterLayer rstlyer = GetRasterLayer(Convert.ToString(comboBox1.SelectedItem));
IRasterBandCollection bdcol = rstlyer.Raster as IRasterBandCollection;
IRasterBand rband = bdcol.Item(0);
string fullname = Convert.ToString(comboBox1.SelectedItem);
int index = fullname.IndexOf(".");
string rstnm = fullname.Substring(0, index);
rstcal.BindRaster(rband as IGeoDataset,"rst01");
string excute = "[rst01]/4";
IGeoDataset gd = rstcal.Execute(excute);
代码如下:
IMapAlgebraOp rstcal = new RasterMapAlgebraOpClass();
IRasterLayer rstlyer = GetRasterLayer(Convert.ToString(comboBox1.SelectedItem));
IRasterBandCollection bdcol = rstlyer.Raster as IRasterBandCollection;
IRasterBand rband = bdcol.Item(0);
string fullname = Convert.ToString(comboBox1.SelectedItem);
int index = fullname.IndexOf(".");
string rstnm = fullname.Substring(0, index);
rstcal.BindRaster(rband as IGeoDataset,"rst01");
string excute = "[rst01]/4";
IGeoDataset gd = rstcal.Execute(excute);
1 个回复
朱新颖
赞同来自: gisxiaotian
要回复问题请先登录或注册