HtmlWindow.AttachEventHandler(String, EventHandler) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Adds an event handler for the named HTML DOM event.
public:
void AttachEventHandler(System::String ^ eventName, EventHandler ^ eventHandler);
public void AttachEventHandler (string eventName, EventHandler eventHandler);
member this.AttachEventHandler : string * EventHandler -> unit
Public Sub AttachEventHandler (eventName As String, eventHandler As EventHandler)
Parameters
- eventName
- String
The name of the event you want to handle.
- eventHandler
- EventHandler
A reference to the managed code that handles the event.
Remarks
You should not attach an event to an HTML document or one of its objects until the document has completed loading. The earliest you should call this method is in the DocumentCompleted event of the WebBrowser control.
Applies to
See also
שתף איתנו פעולה ב- GitHub
ניתן למצוא את המקור לתוכן זה ב- GitHub, שם ניתן גם ליצור ולסקור בעיות ולמשוך בקשות. לקבלת מידע נוסף, עיין במדריך התורמים שלנו.