Share via


EVENT_DELEGATE_ENTRY

Creates an entry in the delegate map.

EVENT_DELEGATE_ENTRY(
   MEMBER,
   ARG0,
   ARG1
);

Parameters

  • MEMBER
    The event handler method to be attached to the control.

  • ARG0
    The first argument of the managed event handler method, such as Object^.

  • ARG1
    The second argument of the managed event handler method, such as EventArgs^.

Remarks

Each entry in the delegate map corresponds to a managed event handler delegate created by MAKE_DELEGATE.

Example

The following code example shows how to use EVENT_DELEGATE_ENTRY to create an entry in the delegate map for the OnClick event handler; also see the code example in MAKE_DELEGATE. For more information, see How to: Sink Windows Forms Events from Native C++ Classes.

BEGIN_DELEGATE_MAP(CMyView)
   EVENT_DELEGATE_ENTRY(OnClick, System::Object^, System::EventArgs^)
END_DELEGATE_MAP()

Requirements

Header: msclr\event.h

See Also

Reference

MAKE_DELEGATE

BEGIN_DELEGATE_MAP

END_DELEGATE_MAP