ListControl.FormatStringChanged 事件

定義

當房產價值 FormatString 變動時,會發生這種情況。

public:
 event EventHandler ^ FormatStringChanged;
public event EventHandler FormatStringChanged;
member this.FormatStringChanged : EventHandler 
Public Custom Event FormatStringChanged As EventHandler 

事件類型

範例

以下程式碼範例展示了此成員的使用方式。 在這個例子中,事件處理者會回報事件 FormatStringChanged 的發生情況。 此報告能幫助您了解事件發生時間,並協助除錯。 若要報告多個事件或頻繁發生的事件,請考慮將MessageBox.Show訊息替換Console.WriteLine為或附加於多行TextBox

要執行範例程式碼,將它貼到包含繼承自 ListControl的型別實例的專案中,例如 a ComboBoxListBox。 接著命名實例 ListControl1 ,並確保事件處理程序與事件 FormatStringChanged 相關聯。

private void ListControl1_FormatStringChanged(Object sender, EventArgs e) {

   MessageBox.Show("You are in the ListControl.FormatStringChanged event.");
}
Private Sub ListControl1_FormatStringChanged(sender as Object, e as EventArgs) _ 
     Handles ListControl1.FormatStringChanged

   MessageBox.Show("You are in the ListControl.FormatStringChanged event.")

End Sub

備註

如需處理事件的詳細資訊,請參閱 處理和引發事件

適用於