How to change the raster NoData value with ArcObjects?

المشرف العام

Administrator
طاقم الإدارة
I am trying to change the a raster's NoData value with ArcObjects and keep coming up short.

Here is the code that I thought would work:

IRasterDataset _dataset = ...get the dataset...object[] noDataValue = ...set the no data values by raster band...var rasterbandCollection = (IRasterBandCollection) _dataset;for(int i = 0; i < rasterbandCollection.Count; i++){ ((IRasterProps) rasterbandCollection.Item(i)).NoDataValue = noDataValue;}This value persists during the ArcMap session, but does not save the changes to disk it appears. Any ideas on how to make this permanent (without having to save a second raster dataset)?



أكثر...
 
أعلى