Platform SDK: Exchange 2000 Server

INNTPOnPostEarly Interface

[This is preliminary documentation and subject to change.]

The INNTPOnPostEarly interface defines the interface between event sinks written with CDO and the NNTP service OnPostEarly event source.

IID
CD000033-8B95-11D1-82DB-00C04FB1625D
Extends
IDispatch

Member Summary

Method

Name Description
OnPostEarly Called by the NNTP event source on bound OnPostEarly event sinks when message or news feed headers arrive to the NNTP service but before the message content has arrived.

Remarks

To implement an NNTP OnPostEarly event sink using CDO, you create and register a local COM class that exposes the CDO INNTPOnPostEarly interface.

For more information on implementing NNTP OnPostEarly event sinks, see SMTP/NNTP Transport Event Sinks with CDO.

Example

[C++,IDL]

The code below is an example using the Active Template Library (ATL) to implement an NNTP OnPostEarly event sink.

#include "StdAfx.h"
#include "sinkproj.h"  // contains guids for this class
#include "resource.h"
#import "c:\program files\common files\system\ado\msado15.dll" no_namespace
#import "c:\exchsrvr\bin\cdoex.dll" raw_interfaces_only no_namespace

class ATL_NO_VTABLE CMyClass :
    public CComObjectRootEx<CComSingleThreadModel>,
    public CComCoClass<CMyClass,&CLSID_MyClass>,
    public IDispatchImpl<INNTPOnPostEarly,&__uuidof(INNTPOnPostEarly),&LIBID_MyClass>
{
public:
     CMyClass() {}
DECLARE_REGISTRY_RESOURCEID(IDR_MyClass)
DECLARE_NOT_AGGREGATABLE(CMyClass)

BEGIN_COM_MAP(CMyClass)
  COM_INTERFACE_ENTRY(INNTPOnPostEarly)
  COM_INTERFACE_ENTRY(IDispatch)
END_COM_MAP()

// INNTPOnPostEarly
public:
   STDMETHOD(OnPostEarly) (/* in */ IMessage* pMsg, /* in,out */ CdoEventStatus* EventStatus);
private:
   // any other custom methods you wish to use
   
};

CMyClass::OnPostEarly( IMessage* pMsg, CdoEventStatus* EventStatus)
{
   // TODO:  add sink code here
} 
[Visual Basic]
' References to ADO 2.5 and CDO for Microsoft Exchange
Implements CDO.INNTPOnPostEarly

Private Sub INNTPOnPostEarly_OnPostEarly( ByVal Msg as IMessage,  EventStatus as CdoEventStatus )
  '  Add handling code here
End Sub
[VBScript]
<SCRIPT LANGUAGE="VBScript">
Sub INNTPOnPostEarly_OnPostEarly( ByVal Msg, EventStatus)
  ' Add sink code here
End Sub
</SCRIPT>

See Also

SMTP/NNTP Transport Event Sinks with _CDO

INNTPOnPost Interface

INNTPOnPostFinal Interface