Control.OnNotifyMessage(Message) メソッド
定義
コントロールに Windows メッセージを通知します。Notifies the control of Windows messages.
protected:
virtual void OnNotifyMessage(System::Windows::Forms::Message m);
protected virtual void OnNotifyMessage (System.Windows.Forms.Message m);
abstract member OnNotifyMessage : System.Windows.Forms.Message -> unit
override this.OnNotifyMessage : System.Windows.Forms.Message -> unit
Protected Overridable Sub OnNotifyMessage (m As Message)
パラメーター
注釈
OnNotifyMessage メソッドは、コントロールの EnableNotifyMessage
スタイルビットが ControlStylesに設定されている場合に呼び出されます。The OnNotifyMessage method is called if the control's EnableNotifyMessage
style bit is set in ControlStyles. ControlStyles の EnableNotifyMessage
スタイルを使用すると、WndProc メソッドが Windows メッセージを受信したときに、コントロールに通知を送信できます。The EnableNotifyMessage
style in ControlStyles enables the control to be notified when the WndProc method receives a Windows message. このメソッドを使用すると、部分的に信頼されたコントロールは、メッセージを変更することなく、Windows メッセージをリッスンできます。With this method, semi-trusted controls can listen for Windows messages without enabling them to modify the message.
注意 (継承者)
派生クラスで OnNotifyMessage(Message) をオーバーライドする場合、基本クラスの OnNotifyMessage(Message) メソッドを呼び出す必要はありません。初期実装がないためです。When overriding OnNotifyMessage(Message) in a derived class, calling the base class's OnNotifyMessage(Message) method is not necessary because there is no initial implementation.