Imports Infragistics.Shared
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinGrid
Imports System.Diagnostics
Private Sub Button112_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles button112.Click
Dim bands As BandsCollection = Me.UltraGrid1.DisplayLayout.Bands
' Loop through all the bands.
Dim band As UltraGridBand
For Each band In bands
' Get the origin and the extent.
Dim origin As Integer = band.GetOrigin(BandOrigin.PreRowArea)
Dim extent As Integer = band.GetExtent(BandOrigin.PreRowArea)
' Write out the origin and the extent.
Debug.WriteLine("bands(" & band.Index & ") Origin = " & origin & ", Extent = " & extent)
Next
End Sub