Click here to Skip to main content
Click here to Skip to main content
Add your own
alternative version

Understanding The COM Single-Threaded Apartment Part 1

, 6 Jan 2005 CPOL
Learn the fundamental principles of the COM Single-Threaded Apartment Model by code examples.
ccomthread_src.zip
LegacyCOMObject1
Shared
SimpleCOMObject1
SimpleCOMObject2
Test Programs
LegacyCOMObject1.def
LegacyCOMObject1.dsp
LegacyCOMObject1.dsw
LegacyCOMObject1.rgs
LegacyCOMObject1.tlb
LegacyCOMObject1ps.def
LegacyCOMObject1ps.mk
SimpleCOMObject1.def
SimpleCOMObject1.dsp
SimpleCOMObject1.dsw
SimpleCOMObject1.rgs
SimpleCOMObject1.tlb
SimpleCOMObject1ps.def
SimpleCOMObject1ps.mk
SimpleCOMObject2.def
SimpleCOMObject2.dsp
SimpleCOMObject2.dsw
SimpleCOMObject2.rgs
SimpleCOMObject2.tlb
SimpleCOMObject2ps.def
SimpleCOMObject2ps.mk
VBTest
VCTests
FormMain.frm
MSSCCPRJ.SCC
VBTest.exe
VBTest.vbp
VBTest.vbw
DemonstrateDefaultSTA
DemonstrateExeServerSTA
DemonstrateLegacySTA
DemonstrateNoMessageLoop
DemonstrateSTA
VCTest01
VCTest02
SimpleCOMObject2.tlh
SimpleCOMObject2.tli
VCTest01.dsp
VCTest01.dsw
SimpleCOMObject2.tlh
SimpleCOMObject2.tli
VCTest02.dsp
VCTest02.dsw
Client
Implementation
Interface
VCTest01
VCTest01.dsp
VCTest01.dsw
ExeServerImpl
ExeServerImpl.dsp
ExeServerImpl.dsw
ExeServerInterfaces
ExeObj01.rgs
ExeObj02.rgs
ExeObj03.rgs
ExeServerInterfaces.def
ExeServerInterfaces.dsp
ExeServerInterfaces.dsw
ExeServerInterfaces.tlb
ExeServerInterfacesps.def
ExeServerInterfacesps.mk
VCTest01
VCTest02
LegacyCOMObject1.tlh
LegacyCOMObject1.tli
VCTest01.dsp
VCTest01.dsw
VCTest02.dsp
VCTest02.dsw
VCTest01
SimpleCOMObject2.tlh
SimpleCOMObject2.tli
VCTest01.dsp
VCTest01.dsw
VCTest01
SimpleCOMObject2.tlh
SimpleCOMObject2.tli
VCTest01.dsp
VCTest01.dsw
/* this ALWAYS GENERATED file contains the definitions for the interfaces */


/* File created by MIDL compiler version 5.01.0164 */
/* at Wed Dec 29 16:46:00 2004
 */
/* Compiler settings for F:\Limbl\Develope\CodeProject\CCOMThread\Test Programs\VCTests\DemonstrateExeServerSTA\Interface\ExeServerInterfaces\ExeServerInterfaces.idl:
    Oicf (OptLev=i2), W1, Zp8, env=Win32, ms_ext, c_ext
    error checks: allocation ref bounds_check enum stub_data 
*/
//@@MIDL_FILE_HEADING(  )


/* verify that the <rpcndr.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCNDR_H_VERSION__
#define __REQUIRED_RPCNDR_H_VERSION__ 440
#endif

#include "rpc.h"
#include "rpcndr.h"

#ifndef __RPCNDR_H_VERSION__
#error this stub requires an updated version of <rpcndr.h>
#endif // __RPCNDR_H_VERSION__

#ifndef COM_NO_WINDOWS_H
#include "windows.h"
#include "ole2.h"
#endif /*COM_NO_WINDOWS_H*/

#ifndef __ExeServerInterfaces_h__
#define __ExeServerInterfaces_h__

#ifdef __cplusplus
extern "C"{
#endif 

/* Forward Declarations */ 

#ifndef __IExeObj01_FWD_DEFINED__
#define __IExeObj01_FWD_DEFINED__
typedef interface IExeObj01 IExeObj01;
#endif 	/* __IExeObj01_FWD_DEFINED__ */


#ifndef ___IExeObj01Events_FWD_DEFINED__
#define ___IExeObj01Events_FWD_DEFINED__
typedef interface _IExeObj01Events _IExeObj01Events;
#endif 	/* ___IExeObj01Events_FWD_DEFINED__ */


#ifndef __IExeObj02_FWD_DEFINED__
#define __IExeObj02_FWD_DEFINED__
typedef interface IExeObj02 IExeObj02;
#endif 	/* __IExeObj02_FWD_DEFINED__ */


#ifndef __ExeObj01_FWD_DEFINED__
#define __ExeObj01_FWD_DEFINED__

#ifdef __cplusplus
typedef class ExeObj01 ExeObj01;
#else
typedef struct ExeObj01 ExeObj01;
#endif /* __cplusplus */

#endif 	/* __ExeObj01_FWD_DEFINED__ */


#ifndef ___IExeObj02Events_FWD_DEFINED__
#define ___IExeObj02Events_FWD_DEFINED__
typedef interface _IExeObj02Events _IExeObj02Events;
#endif 	/* ___IExeObj02Events_FWD_DEFINED__ */


#ifndef __IExeObj03_FWD_DEFINED__
#define __IExeObj03_FWD_DEFINED__
typedef interface IExeObj03 IExeObj03;
#endif 	/* __IExeObj03_FWD_DEFINED__ */


#ifndef __ExeObj02_FWD_DEFINED__
#define __ExeObj02_FWD_DEFINED__

#ifdef __cplusplus
typedef class ExeObj02 ExeObj02;
#else
typedef struct ExeObj02 ExeObj02;
#endif /* __cplusplus */

#endif 	/* __ExeObj02_FWD_DEFINED__ */


#ifndef ___IExeObj03Events_FWD_DEFINED__
#define ___IExeObj03Events_FWD_DEFINED__
typedef interface _IExeObj03Events _IExeObj03Events;
#endif 	/* ___IExeObj03Events_FWD_DEFINED__ */


#ifndef __ExeObj03_FWD_DEFINED__
#define __ExeObj03_FWD_DEFINED__

#ifdef __cplusplus
typedef class ExeObj03 ExeObj03;
#else
typedef struct ExeObj03 ExeObj03;
#endif /* __cplusplus */

#endif 	/* __ExeObj03_FWD_DEFINED__ */


/* header files for imported files */
#include "oaidl.h"
#include "ocidl.h"

void __RPC_FAR * __RPC_USER MIDL_user_allocate(size_t);
void __RPC_USER MIDL_user_free( void __RPC_FAR * ); 

#ifndef __IExeObj01_INTERFACE_DEFINED__
#define __IExeObj01_INTERFACE_DEFINED__

/* interface IExeObj01 */
/* [unique][helpstring][dual][uuid][object] */ 


EXTERN_C const IID IID_IExeObj01;

#if defined(__cplusplus) && !defined(CINTERFACE)
    
    MIDL_INTERFACE("FF28C486-518D-4EA2-9E0E-FE4F9E791C9C")
    IExeObj01 : public IDispatch
    {
    public:
        virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE TestMethod1( void) = 0;
        
    };
    
#else 	/* C style interface */

    typedef struct IExeObj01Vtbl
    {
        BEGIN_INTERFACE
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *QueryInterface )( 
            IExeObj01 __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [iid_is][out] */ void __RPC_FAR *__RPC_FAR *ppvObject);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *AddRef )( 
            IExeObj01 __RPC_FAR * This);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *Release )( 
            IExeObj01 __RPC_FAR * This);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfoCount )( 
            IExeObj01 __RPC_FAR * This,
            /* [out] */ UINT __RPC_FAR *pctinfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfo )( 
            IExeObj01 __RPC_FAR * This,
            /* [in] */ UINT iTInfo,
            /* [in] */ LCID lcid,
            /* [out] */ ITypeInfo __RPC_FAR *__RPC_FAR *ppTInfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetIDsOfNames )( 
            IExeObj01 __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [size_is][in] */ LPOLESTR __RPC_FAR *rgszNames,
            /* [in] */ UINT cNames,
            /* [in] */ LCID lcid,
            /* [size_is][out] */ DISPID __RPC_FAR *rgDispId);
        
        /* [local] */ HRESULT ( STDMETHODCALLTYPE __RPC_FAR *Invoke )( 
            IExeObj01 __RPC_FAR * This,
            /* [in] */ DISPID dispIdMember,
            /* [in] */ REFIID riid,
            /* [in] */ LCID lcid,
            /* [in] */ WORD wFlags,
            /* [out][in] */ DISPPARAMS __RPC_FAR *pDispParams,
            /* [out] */ VARIANT __RPC_FAR *pVarResult,
            /* [out] */ EXCEPINFO __RPC_FAR *pExcepInfo,
            /* [out] */ UINT __RPC_FAR *puArgErr);
        
        /* [helpstring][id] */ HRESULT ( STDMETHODCALLTYPE __RPC_FAR *TestMethod1 )( 
            IExeObj01 __RPC_FAR * This);
        
        END_INTERFACE
    } IExeObj01Vtbl;

    interface IExeObj01
    {
        CONST_VTBL struct IExeObj01Vtbl __RPC_FAR *lpVtbl;
    };

    

#ifdef COBJMACROS


#define IExeObj01_QueryInterface(This,riid,ppvObject)	\
    (This)->lpVtbl -> QueryInterface(This,riid,ppvObject)

#define IExeObj01_AddRef(This)	\
    (This)->lpVtbl -> AddRef(This)

#define IExeObj01_Release(This)	\
    (This)->lpVtbl -> Release(This)


#define IExeObj01_GetTypeInfoCount(This,pctinfo)	\
    (This)->lpVtbl -> GetTypeInfoCount(This,pctinfo)

#define IExeObj01_GetTypeInfo(This,iTInfo,lcid,ppTInfo)	\
    (This)->lpVtbl -> GetTypeInfo(This,iTInfo,lcid,ppTInfo)

#define IExeObj01_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)	\
    (This)->lpVtbl -> GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)

#define IExeObj01_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)	\
    (This)->lpVtbl -> Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)


#define IExeObj01_TestMethod1(This)	\
    (This)->lpVtbl -> TestMethod1(This)

#endif /* COBJMACROS */


#endif 	/* C style interface */



/* [helpstring][id] */ HRESULT STDMETHODCALLTYPE IExeObj01_TestMethod1_Proxy( 
    IExeObj01 __RPC_FAR * This);


void __RPC_STUB IExeObj01_TestMethod1_Stub(
    IRpcStubBuffer *This,
    IRpcChannelBuffer *_pRpcChannelBuffer,
    PRPC_MESSAGE _pRpcMessage,
    DWORD *_pdwStubPhase);



#endif 	/* __IExeObj01_INTERFACE_DEFINED__ */



#ifndef __EXESERVERINTERFACESLib_LIBRARY_DEFINED__
#define __EXESERVERINTERFACESLib_LIBRARY_DEFINED__

/* library EXESERVERINTERFACESLib */
/* [helpstring][version][uuid] */ 


EXTERN_C const IID LIBID_EXESERVERINTERFACESLib;

#ifndef ___IExeObj01Events_DISPINTERFACE_DEFINED__
#define ___IExeObj01Events_DISPINTERFACE_DEFINED__

/* dispinterface _IExeObj01Events */
/* [helpstring][uuid] */ 


EXTERN_C const IID DIID__IExeObj01Events;

#if defined(__cplusplus) && !defined(CINTERFACE)

    MIDL_INTERFACE("3EEC53F4-42A0-4E0F-B059-975E84DCAAA9")
    _IExeObj01Events : public IDispatch
    {
    };
    
#else 	/* C style interface */

    typedef struct _IExeObj01EventsVtbl
    {
        BEGIN_INTERFACE
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *QueryInterface )( 
            _IExeObj01Events __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [iid_is][out] */ void __RPC_FAR *__RPC_FAR *ppvObject);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *AddRef )( 
            _IExeObj01Events __RPC_FAR * This);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *Release )( 
            _IExeObj01Events __RPC_FAR * This);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfoCount )( 
            _IExeObj01Events __RPC_FAR * This,
            /* [out] */ UINT __RPC_FAR *pctinfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfo )( 
            _IExeObj01Events __RPC_FAR * This,
            /* [in] */ UINT iTInfo,
            /* [in] */ LCID lcid,
            /* [out] */ ITypeInfo __RPC_FAR *__RPC_FAR *ppTInfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetIDsOfNames )( 
            _IExeObj01Events __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [size_is][in] */ LPOLESTR __RPC_FAR *rgszNames,
            /* [in] */ UINT cNames,
            /* [in] */ LCID lcid,
            /* [size_is][out] */ DISPID __RPC_FAR *rgDispId);
        
        /* [local] */ HRESULT ( STDMETHODCALLTYPE __RPC_FAR *Invoke )( 
            _IExeObj01Events __RPC_FAR * This,
            /* [in] */ DISPID dispIdMember,
            /* [in] */ REFIID riid,
            /* [in] */ LCID lcid,
            /* [in] */ WORD wFlags,
            /* [out][in] */ DISPPARAMS __RPC_FAR *pDispParams,
            /* [out] */ VARIANT __RPC_FAR *pVarResult,
            /* [out] */ EXCEPINFO __RPC_FAR *pExcepInfo,
            /* [out] */ UINT __RPC_FAR *puArgErr);
        
        END_INTERFACE
    } _IExeObj01EventsVtbl;

    interface _IExeObj01Events
    {
        CONST_VTBL struct _IExeObj01EventsVtbl __RPC_FAR *lpVtbl;
    };

    

#ifdef COBJMACROS


#define _IExeObj01Events_QueryInterface(This,riid,ppvObject)	\
    (This)->lpVtbl -> QueryInterface(This,riid,ppvObject)

#define _IExeObj01Events_AddRef(This)	\
    (This)->lpVtbl -> AddRef(This)

#define _IExeObj01Events_Release(This)	\
    (This)->lpVtbl -> Release(This)


#define _IExeObj01Events_GetTypeInfoCount(This,pctinfo)	\
    (This)->lpVtbl -> GetTypeInfoCount(This,pctinfo)

#define _IExeObj01Events_GetTypeInfo(This,iTInfo,lcid,ppTInfo)	\
    (This)->lpVtbl -> GetTypeInfo(This,iTInfo,lcid,ppTInfo)

#define _IExeObj01Events_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)	\
    (This)->lpVtbl -> GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)

#define _IExeObj01Events_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)	\
    (This)->lpVtbl -> Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)

#endif /* COBJMACROS */


#endif 	/* C style interface */


#endif 	/* ___IExeObj01Events_DISPINTERFACE_DEFINED__ */


#ifndef __IExeObj02_INTERFACE_DEFINED__
#define __IExeObj02_INTERFACE_DEFINED__

/* interface IExeObj02 */
/* [unique][helpstring][dual][uuid][object] */ 


EXTERN_C const IID IID_IExeObj02;

#if defined(__cplusplus) && !defined(CINTERFACE)
    
    MIDL_INTERFACE("7C0808AE-195D-4A95-B0B8-D53599E677EB")
    IExeObj02 : public IDispatch
    {
    public:
        virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE TestMethod1( void) = 0;
        
    };
    
#else 	/* C style interface */

    typedef struct IExeObj02Vtbl
    {
        BEGIN_INTERFACE
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *QueryInterface )( 
            IExeObj02 __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [iid_is][out] */ void __RPC_FAR *__RPC_FAR *ppvObject);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *AddRef )( 
            IExeObj02 __RPC_FAR * This);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *Release )( 
            IExeObj02 __RPC_FAR * This);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfoCount )( 
            IExeObj02 __RPC_FAR * This,
            /* [out] */ UINT __RPC_FAR *pctinfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfo )( 
            IExeObj02 __RPC_FAR * This,
            /* [in] */ UINT iTInfo,
            /* [in] */ LCID lcid,
            /* [out] */ ITypeInfo __RPC_FAR *__RPC_FAR *ppTInfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetIDsOfNames )( 
            IExeObj02 __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [size_is][in] */ LPOLESTR __RPC_FAR *rgszNames,
            /* [in] */ UINT cNames,
            /* [in] */ LCID lcid,
            /* [size_is][out] */ DISPID __RPC_FAR *rgDispId);
        
        /* [local] */ HRESULT ( STDMETHODCALLTYPE __RPC_FAR *Invoke )( 
            IExeObj02 __RPC_FAR * This,
            /* [in] */ DISPID dispIdMember,
            /* [in] */ REFIID riid,
            /* [in] */ LCID lcid,
            /* [in] */ WORD wFlags,
            /* [out][in] */ DISPPARAMS __RPC_FAR *pDispParams,
            /* [out] */ VARIANT __RPC_FAR *pVarResult,
            /* [out] */ EXCEPINFO __RPC_FAR *pExcepInfo,
            /* [out] */ UINT __RPC_FAR *puArgErr);
        
        /* [helpstring][id] */ HRESULT ( STDMETHODCALLTYPE __RPC_FAR *TestMethod1 )( 
            IExeObj02 __RPC_FAR * This);
        
        END_INTERFACE
    } IExeObj02Vtbl;

    interface IExeObj02
    {
        CONST_VTBL struct IExeObj02Vtbl __RPC_FAR *lpVtbl;
    };

    

#ifdef COBJMACROS


#define IExeObj02_QueryInterface(This,riid,ppvObject)	\
    (This)->lpVtbl -> QueryInterface(This,riid,ppvObject)

#define IExeObj02_AddRef(This)	\
    (This)->lpVtbl -> AddRef(This)

#define IExeObj02_Release(This)	\
    (This)->lpVtbl -> Release(This)


#define IExeObj02_GetTypeInfoCount(This,pctinfo)	\
    (This)->lpVtbl -> GetTypeInfoCount(This,pctinfo)

#define IExeObj02_GetTypeInfo(This,iTInfo,lcid,ppTInfo)	\
    (This)->lpVtbl -> GetTypeInfo(This,iTInfo,lcid,ppTInfo)

#define IExeObj02_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)	\
    (This)->lpVtbl -> GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)

#define IExeObj02_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)	\
    (This)->lpVtbl -> Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)


#define IExeObj02_TestMethod1(This)	\
    (This)->lpVtbl -> TestMethod1(This)

#endif /* COBJMACROS */


#endif 	/* C style interface */



/* [helpstring][id] */ HRESULT STDMETHODCALLTYPE IExeObj02_TestMethod1_Proxy( 
    IExeObj02 __RPC_FAR * This);


void __RPC_STUB IExeObj02_TestMethod1_Stub(
    IRpcStubBuffer *This,
    IRpcChannelBuffer *_pRpcChannelBuffer,
    PRPC_MESSAGE _pRpcMessage,
    DWORD *_pdwStubPhase);



#endif 	/* __IExeObj02_INTERFACE_DEFINED__ */


EXTERN_C const CLSID CLSID_ExeObj01;

#ifdef __cplusplus

class DECLSPEC_UUID("3AEF8F56-E35F-43F9-B052-7CF96205838C")
ExeObj01;
#endif

#ifndef ___IExeObj02Events_DISPINTERFACE_DEFINED__
#define ___IExeObj02Events_DISPINTERFACE_DEFINED__

/* dispinterface _IExeObj02Events */
/* [helpstring][uuid] */ 


EXTERN_C const IID DIID__IExeObj02Events;

#if defined(__cplusplus) && !defined(CINTERFACE)

    MIDL_INTERFACE("38AAAE6D-3BBB-4592-8D75-EEF243E7E6D0")
    _IExeObj02Events : public IDispatch
    {
    };
    
#else 	/* C style interface */

    typedef struct _IExeObj02EventsVtbl
    {
        BEGIN_INTERFACE
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *QueryInterface )( 
            _IExeObj02Events __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [iid_is][out] */ void __RPC_FAR *__RPC_FAR *ppvObject);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *AddRef )( 
            _IExeObj02Events __RPC_FAR * This);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *Release )( 
            _IExeObj02Events __RPC_FAR * This);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfoCount )( 
            _IExeObj02Events __RPC_FAR * This,
            /* [out] */ UINT __RPC_FAR *pctinfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfo )( 
            _IExeObj02Events __RPC_FAR * This,
            /* [in] */ UINT iTInfo,
            /* [in] */ LCID lcid,
            /* [out] */ ITypeInfo __RPC_FAR *__RPC_FAR *ppTInfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetIDsOfNames )( 
            _IExeObj02Events __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [size_is][in] */ LPOLESTR __RPC_FAR *rgszNames,
            /* [in] */ UINT cNames,
            /* [in] */ LCID lcid,
            /* [size_is][out] */ DISPID __RPC_FAR *rgDispId);
        
        /* [local] */ HRESULT ( STDMETHODCALLTYPE __RPC_FAR *Invoke )( 
            _IExeObj02Events __RPC_FAR * This,
            /* [in] */ DISPID dispIdMember,
            /* [in] */ REFIID riid,
            /* [in] */ LCID lcid,
            /* [in] */ WORD wFlags,
            /* [out][in] */ DISPPARAMS __RPC_FAR *pDispParams,
            /* [out] */ VARIANT __RPC_FAR *pVarResult,
            /* [out] */ EXCEPINFO __RPC_FAR *pExcepInfo,
            /* [out] */ UINT __RPC_FAR *puArgErr);
        
        END_INTERFACE
    } _IExeObj02EventsVtbl;

    interface _IExeObj02Events
    {
        CONST_VTBL struct _IExeObj02EventsVtbl __RPC_FAR *lpVtbl;
    };

    

#ifdef COBJMACROS


#define _IExeObj02Events_QueryInterface(This,riid,ppvObject)	\
    (This)->lpVtbl -> QueryInterface(This,riid,ppvObject)

#define _IExeObj02Events_AddRef(This)	\
    (This)->lpVtbl -> AddRef(This)

#define _IExeObj02Events_Release(This)	\
    (This)->lpVtbl -> Release(This)


#define _IExeObj02Events_GetTypeInfoCount(This,pctinfo)	\
    (This)->lpVtbl -> GetTypeInfoCount(This,pctinfo)

#define _IExeObj02Events_GetTypeInfo(This,iTInfo,lcid,ppTInfo)	\
    (This)->lpVtbl -> GetTypeInfo(This,iTInfo,lcid,ppTInfo)

#define _IExeObj02Events_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)	\
    (This)->lpVtbl -> GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)

#define _IExeObj02Events_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)	\
    (This)->lpVtbl -> Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)

#endif /* COBJMACROS */


#endif 	/* C style interface */


#endif 	/* ___IExeObj02Events_DISPINTERFACE_DEFINED__ */


#ifndef __IExeObj03_INTERFACE_DEFINED__
#define __IExeObj03_INTERFACE_DEFINED__

/* interface IExeObj03 */
/* [unique][helpstring][dual][uuid][object] */ 


EXTERN_C const IID IID_IExeObj03;

#if defined(__cplusplus) && !defined(CINTERFACE)
    
    MIDL_INTERFACE("81215C83-184B-4D29-8624-2896942B16FC")
    IExeObj03 : public IDispatch
    {
    public:
        virtual /* [helpstring][id] */ HRESULT STDMETHODCALLTYPE TestMethod1( void) = 0;
        
    };
    
#else 	/* C style interface */

    typedef struct IExeObj03Vtbl
    {
        BEGIN_INTERFACE
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *QueryInterface )( 
            IExeObj03 __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [iid_is][out] */ void __RPC_FAR *__RPC_FAR *ppvObject);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *AddRef )( 
            IExeObj03 __RPC_FAR * This);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *Release )( 
            IExeObj03 __RPC_FAR * This);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfoCount )( 
            IExeObj03 __RPC_FAR * This,
            /* [out] */ UINT __RPC_FAR *pctinfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfo )( 
            IExeObj03 __RPC_FAR * This,
            /* [in] */ UINT iTInfo,
            /* [in] */ LCID lcid,
            /* [out] */ ITypeInfo __RPC_FAR *__RPC_FAR *ppTInfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetIDsOfNames )( 
            IExeObj03 __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [size_is][in] */ LPOLESTR __RPC_FAR *rgszNames,
            /* [in] */ UINT cNames,
            /* [in] */ LCID lcid,
            /* [size_is][out] */ DISPID __RPC_FAR *rgDispId);
        
        /* [local] */ HRESULT ( STDMETHODCALLTYPE __RPC_FAR *Invoke )( 
            IExeObj03 __RPC_FAR * This,
            /* [in] */ DISPID dispIdMember,
            /* [in] */ REFIID riid,
            /* [in] */ LCID lcid,
            /* [in] */ WORD wFlags,
            /* [out][in] */ DISPPARAMS __RPC_FAR *pDispParams,
            /* [out] */ VARIANT __RPC_FAR *pVarResult,
            /* [out] */ EXCEPINFO __RPC_FAR *pExcepInfo,
            /* [out] */ UINT __RPC_FAR *puArgErr);
        
        /* [helpstring][id] */ HRESULT ( STDMETHODCALLTYPE __RPC_FAR *TestMethod1 )( 
            IExeObj03 __RPC_FAR * This);
        
        END_INTERFACE
    } IExeObj03Vtbl;

    interface IExeObj03
    {
        CONST_VTBL struct IExeObj03Vtbl __RPC_FAR *lpVtbl;
    };

    

#ifdef COBJMACROS


#define IExeObj03_QueryInterface(This,riid,ppvObject)	\
    (This)->lpVtbl -> QueryInterface(This,riid,ppvObject)

#define IExeObj03_AddRef(This)	\
    (This)->lpVtbl -> AddRef(This)

#define IExeObj03_Release(This)	\
    (This)->lpVtbl -> Release(This)


#define IExeObj03_GetTypeInfoCount(This,pctinfo)	\
    (This)->lpVtbl -> GetTypeInfoCount(This,pctinfo)

#define IExeObj03_GetTypeInfo(This,iTInfo,lcid,ppTInfo)	\
    (This)->lpVtbl -> GetTypeInfo(This,iTInfo,lcid,ppTInfo)

#define IExeObj03_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)	\
    (This)->lpVtbl -> GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)

#define IExeObj03_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)	\
    (This)->lpVtbl -> Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)


#define IExeObj03_TestMethod1(This)	\
    (This)->lpVtbl -> TestMethod1(This)

#endif /* COBJMACROS */


#endif 	/* C style interface */



/* [helpstring][id] */ HRESULT STDMETHODCALLTYPE IExeObj03_TestMethod1_Proxy( 
    IExeObj03 __RPC_FAR * This);


void __RPC_STUB IExeObj03_TestMethod1_Stub(
    IRpcStubBuffer *This,
    IRpcChannelBuffer *_pRpcChannelBuffer,
    PRPC_MESSAGE _pRpcMessage,
    DWORD *_pdwStubPhase);



#endif 	/* __IExeObj03_INTERFACE_DEFINED__ */


EXTERN_C const CLSID CLSID_ExeObj02;

#ifdef __cplusplus

class DECLSPEC_UUID("48F0E11C-95E5-415B-9F21-BD876FFB099F")
ExeObj02;
#endif

#ifndef ___IExeObj03Events_DISPINTERFACE_DEFINED__
#define ___IExeObj03Events_DISPINTERFACE_DEFINED__

/* dispinterface _IExeObj03Events */
/* [helpstring][uuid] */ 


EXTERN_C const IID DIID__IExeObj03Events;

#if defined(__cplusplus) && !defined(CINTERFACE)

    MIDL_INTERFACE("792EDC47-EBAF-4F3D-BF88-D202622C06BB")
    _IExeObj03Events : public IDispatch
    {
    };
    
#else 	/* C style interface */

    typedef struct _IExeObj03EventsVtbl
    {
        BEGIN_INTERFACE
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *QueryInterface )( 
            _IExeObj03Events __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [iid_is][out] */ void __RPC_FAR *__RPC_FAR *ppvObject);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *AddRef )( 
            _IExeObj03Events __RPC_FAR * This);
        
        ULONG ( STDMETHODCALLTYPE __RPC_FAR *Release )( 
            _IExeObj03Events __RPC_FAR * This);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfoCount )( 
            _IExeObj03Events __RPC_FAR * This,
            /* [out] */ UINT __RPC_FAR *pctinfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetTypeInfo )( 
            _IExeObj03Events __RPC_FAR * This,
            /* [in] */ UINT iTInfo,
            /* [in] */ LCID lcid,
            /* [out] */ ITypeInfo __RPC_FAR *__RPC_FAR *ppTInfo);
        
        HRESULT ( STDMETHODCALLTYPE __RPC_FAR *GetIDsOfNames )( 
            _IExeObj03Events __RPC_FAR * This,
            /* [in] */ REFIID riid,
            /* [size_is][in] */ LPOLESTR __RPC_FAR *rgszNames,
            /* [in] */ UINT cNames,
            /* [in] */ LCID lcid,
            /* [size_is][out] */ DISPID __RPC_FAR *rgDispId);
        
        /* [local] */ HRESULT ( STDMETHODCALLTYPE __RPC_FAR *Invoke )( 
            _IExeObj03Events __RPC_FAR * This,
            /* [in] */ DISPID dispIdMember,
            /* [in] */ REFIID riid,
            /* [in] */ LCID lcid,
            /* [in] */ WORD wFlags,
            /* [out][in] */ DISPPARAMS __RPC_FAR *pDispParams,
            /* [out] */ VARIANT __RPC_FAR *pVarResult,
            /* [out] */ EXCEPINFO __RPC_FAR *pExcepInfo,
            /* [out] */ UINT __RPC_FAR *puArgErr);
        
        END_INTERFACE
    } _IExeObj03EventsVtbl;

    interface _IExeObj03Events
    {
        CONST_VTBL struct _IExeObj03EventsVtbl __RPC_FAR *lpVtbl;
    };

    

#ifdef COBJMACROS


#define _IExeObj03Events_QueryInterface(This,riid,ppvObject)	\
    (This)->lpVtbl -> QueryInterface(This,riid,ppvObject)

#define _IExeObj03Events_AddRef(This)	\
    (This)->lpVtbl -> AddRef(This)

#define _IExeObj03Events_Release(This)	\
    (This)->lpVtbl -> Release(This)


#define _IExeObj03Events_GetTypeInfoCount(This,pctinfo)	\
    (This)->lpVtbl -> GetTypeInfoCount(This,pctinfo)

#define _IExeObj03Events_GetTypeInfo(This,iTInfo,lcid,ppTInfo)	\
    (This)->lpVtbl -> GetTypeInfo(This,iTInfo,lcid,ppTInfo)

#define _IExeObj03Events_GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)	\
    (This)->lpVtbl -> GetIDsOfNames(This,riid,rgszNames,cNames,lcid,rgDispId)

#define _IExeObj03Events_Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)	\
    (This)->lpVtbl -> Invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr)

#endif /* COBJMACROS */


#endif 	/* C style interface */


#endif 	/* ___IExeObj03Events_DISPINTERFACE_DEFINED__ */


EXTERN_C const CLSID CLSID_ExeObj03;

#ifdef __cplusplus

class DECLSPEC_UUID("957C6B07-7645-452D-B3AC-F8FF7E73ABDC")
ExeObj03;
#endif
#endif /* __EXESERVERINTERFACESLib_LIBRARY_DEFINED__ */

/* Additional Prototypes for ALL interfaces */

/* end of Additional Prototypes */

#ifdef __cplusplus
}
#endif

#endif

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Lim Bio Liong
Web Developer
Singapore Singapore
Lim Bio Liong is a Specialist at a leading Software House in Singapore.

Bio has been in software development for over 10 years. He specialises in C/C++ programming and Windows software development.

Bio has also done device-driver development and enjoys low-level programming. Bio has recently picked up C# programming and has been researching in this area.

| Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.150414.1 | Last Updated 6 Jan 2005
Article Copyright 2005 by Lim Bio Liong
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid