共用方式為


DataGrid.LoadingRow 事件

定義

在 a DataGridRow 實例化後發生,讓你在使用前可以自訂它。

public:
 event EventHandler<System::Windows::Controls::DataGridRowEventArgs ^> ^ LoadingRow;
public event EventHandler<System.Windows.Controls.DataGridRowEventArgs> LoadingRow;
member this.LoadingRow : EventHandler<System.Windows.Controls.DataGridRowEventArgs> 
Public Custom Event LoadingRow As EventHandler(Of DataGridRowEventArgs) 
Public Event LoadingRow As EventHandler(Of DataGridRowEventArgs) 

事件類型

備註

為了提升效能,該EnableRowVirtualization屬性預設為 。true 當屬性 EnableRowVirtualization 設為 true時,並 DataGrid 不會為綁定資料來源中的每個資料項目實例化物件 DataGridRow 。 相反地,他們 DataGrid 只在需要時創造 DataGridRow 物品,並盡可能重複使用。 例如,為 DataGrid 目前在視圖中的每個資料項目建立 DataGridRow 一個物件,當資料從視圖中滾動出去時,會回收該列。

此事件允許你在使用前對一列做出必要的變更。 要在某一列被重複使用前還原這些自訂,請處理該 UnloadingRow 事件。

適用於

另請參閱