Search notes:

IDispatch

The IDispatch interface allows for late binding.

C struct of vTable

#ifndef IDISPATCH_VTABLE_INCLUDED
#define IDISPATCH_VTABLE_INCLUDED

#include "IUnknown_vTable.h"

typedef  HRESULT (STDMETHODCALLTYPE *funcPtr_IDispatch_GetTypeInfoCount)(void *self, UINT *pctInfo);
typedef  HRESULT (STDMETHODCALLTYPE *funcPtr_IDispatch_GetTypeInfo     )(void *self, UINT iTInfo, LCID lcid, ITypeInfo **ppTI);
typedef  HRESULT (STDMETHODCALLTYPE *funcPtr_IDispatch_GetIDsOfNames   )(void *self, REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId);
typedef  HRESULT (STDMETHODCALLTYPE *funcPtr_IDispatch_Invoke          )(void *self, DISPID dispidMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pvarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr);

 //
 // Include the three common function pointers (QueryInterface,
 // AddRef and Release) which are defined in the IUNKOWN_VTABLE
 // macro and add the four methods specific to IDispatch:
 // 
#define IDISPATCH_VTABLE                                  \
  IUNKOWN_VTABLE                                          \
  funcPtr_IDispatch_GetTypeInfoCount    GetTypeInfoCount; \
  funcPtr_IDispatch_GetTypeInfo         GetTypeInfo;      \
  funcPtr_IDispatch_GetIDsOfNames       GetIDsOfNames;    \
  funcPtr_IDispatch_Invoke              Invoke;

typedef struct {
   IDISPATCH_VTABLE
}
IDispatch_vTable;

#endif
Github repository about-COM, path: /c/structs/IDispatch_vTable.h

See also

In Visual Basic for Applications, an object is associated with an IDispatch.
DispCallFunc is a low-level helper function for Invoke that provides machine independence for customized Invoke.
IUnknown
oaidl.h

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/Windows/...', 1758201039, '216.73.216.150', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/Windows/development/COM/IUnknown/IDispatch/index(79): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78