Share via


CDynamicChain::SetChainEntry

Adds the specified message map to the collection.

BOOL SetChainEntry( 
   DWORD dwChainID, 
   CMessageMap* pObject, 
   DWORD dwMsgMapID = 0  
);

Parameters

  • dwChainID
    [in] The unique identifier associated with the chained object and its message map.

  • pObject
    [in] A pointer to the chained object declaring the message map. This object must derive from CMessageMap.

  • dwMsgMapID
    [in] The identifier of the message map in the chained object. The default value is 0, which identifies the default message map declared with BEGIN_MSG_MAP. To specify an alternate message map declared with ALT_MSG_MAP(msgMapID), pass msgMapID.

Return Value

TRUE if the message map is successfully added to the collection. Otherwise, FALSE.

Remarks

If the dwChainID value already exists in the collection, its associated object and message map are replaced by pObject and dwMsgMapID, respectively. Otherwise, a new entry is added.

Requirements

Header: atlwin.h

See Also

Reference

CDynamicChain Class

CDynamicChain::CallChain

CDynamicChain::RemoveChainEntry

CHAIN_MSG_MAP_DYNAMIC

Other Resources

CDynamicChain Members