WebBrowser.StatusTextChanged イベント

定義

StatusText プロパティの値が変化すると発生します。

public:
 event EventHandler ^ StatusTextChanged;
[System.ComponentModel.Browsable(false)]
public event EventHandler StatusTextChanged;
[System.ComponentModel.Browsable(false)]
public event EventHandler? StatusTextChanged;
[<System.ComponentModel.Browsable(false)>]
member this.StatusTextChanged : EventHandler 
Public Custom Event StatusTextChanged As EventHandler 
Public Event StatusTextChanged As EventHandler 

イベントの種類

属性

次のコード例では、 イベントのハンドラーStatusTextChangedを使用して、インターネット エクスプローラーと同様のコントロールのWebBrowserステータス バーを実装する方法を示します。 この例では、フォームに というコントロールと というコントロールwebBrowser1StatusBarStatusBar1含まれているWebBrowser必要があります。

完全なコード例については、「方法: Windows フォーム アプリケーションに Web ブラウザー機能を追加する」を参照してください。

// Updates StatusBar1 with the current browser status text.
void WebBrowser1_StatusTextChanged( Object^ /*sender*/, System::EventArgs^ /*e*/ )
{
   this->StatusBar1->Text = WebBrowser1->StatusText;
}
// Updates the status bar with the current browser status text.
private void webBrowser1_StatusTextChanged(object sender, EventArgs e)
{
    toolStripStatusLabel1.Text = webBrowser1.StatusText;
}
' Updates the status bar with the current browser status text.
Private Sub webBrowser1_StatusTextChanged( _
    ByVal sender As Object, ByVal e As EventArgs) _
    Handles webBrowser1.StatusTextChanged

    toolStripStatusLabel1.Text = webBrowser1.StatusText

End Sub

注釈

プロパティの値が変更されたときにステータス バーを更新するには、このイベントを StatusText 処理します。

イベントの処理の詳細については、「処理とイベントの発生」を参照してください。

適用対象

こちらもご覧ください