ArcGIS Pro 2.6 API Reference Guide
GetBandCount Method (RasterDataset)

ArcGIS.Core.Data.Raster Namespace > RasterDataset Class : GetBandCount Method
Gets the number of bands in this raster dataset. This method must be called on the MCT. Use QueuedTask.Run.
Syntax
public int GetBandCount()
Public Function GetBandCount() As Integer

Return Value

An integer representing the number of bands in this raster dataset.
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 7

See Also

Reference

RasterDataset Class
RasterDataset Members