'宣言 Public Property AutoFitColumns As AutoFitColumns
public AutoFitColumns AutoFitColumns {get; set;}
Imports Infragistics.Win Imports Infragistics.Win.UltraWinListView Private Sub EnableAutoFitColumns(ByVal listView As UltraListView) If ListView Is Nothing Then Throw New ArgumentNullException("listView") listView.ViewSettingsDetails.AutoFitColumns = AutoFitColumns.ResizeAllColumns End Sub
using Infragistics.Win; using Infragistics.Win.UltraWinListView; private void EnableAutoFitColumns( UltraListView listView ) { if ( listView == null ) throw new ArgumentNullException( "listView" ); listView.ViewSettingsDetails.AutoFitColumns = AutoFitColumns.ResizeAllColumns; }