outlook add on visual studio 2013 with visual c++ -


i freaking out creating add-on outlook in visual c++. visual studio 2013 not possible create implementation of _idtextensibility2. got different errors! installed office tools vs 2013 won't help. vs2013 running on win 7 enterprise. last error was: "error in onfinish: failed return new code element. possibly syntax error. new element name: _idtextensibility2". happens when try add implemetation atl interface. ideas? nice...:-) thanks! mc

    stdapi dllcanunloadnow(void)     {                 return _atlmodule.dllcanunloadnow();         }     // returns class factory create object of requested type.     stdapi dllgetclassobject(_in_ refclsid rclsid, _in_ refiid riid, _outptr_ lpvoid* ppv)     {             return _atlmodule.dllgetclassobject(rclsid, riid, ppv);     }     // dllregisterserver - adds entries system registry.     stdapi dllregisterserver(void)     {         // registers object, typelib , interfaces in typelib         hresult hr = _atlmodule.dllregisterserver();             return hr;     }     // dllunregisterserver - removes entries system registry.     stdapi dllunregisterserver(void)     {         hresult hr = _atlmodule.dllunregisterserver();             return hr;     }     // dllinstall - adds/removes entries system registry per user per machine.     stdapi dllinstall(bool binstall, _in_opt_  lpcwstr pszcmdline)     {         hresult hr = e_fail;         static const wchar_t szuserswitch[] = l"user";         if (pszcmdline != null)         {             if (_wcsnicmp(pszcmdline, szuserswitch, _countof(szuserswitch)) == 0)             {                 atl::atlsetperuserregistration(true);             }         }         if (binstall)         {                hr = dllregisterserver();             if (failed(hr))             {                 dllunregisterserver();             }         }         else         {             hr = dllunregisterserver();         }         return hr;     }  // , here xxx_p.c file:    // generated file contains proxy stub code    // file created midl compiler version 8.00.0603  //at wed apr 29 16:19:24 2015 // // compiler settings serversoftmail.idl: //    oicf, w1, zp8, env=win32 (32b run), target_arch=x86 8.00.0603  //    protocol : dce , ms_ext, c_ext, robust //    error checks: allocation ref bounds_check enum stub_data  //    vc __declspec() decoration level:  //         __declspec(uuid()), __declspec(selectany), __declspec(novtable) //         declspec_uuid(), midl_interface() // // midl_file_heading  #if !defined(_m_ia64) && !defined(_m_amd64) && !defined(_arm_)   #pragma warning( disable: 4049 )  /* more 64k source lines */ #if _msc_ver >= 1200 #pragma warning(push) #endif  #pragma warning( disable: 4211 )  /* redefine extern static */ #pragma warning( disable: 4232 )  /* dllimport identity*/ #pragma warning( disable: 4024 )  /* array pointer mapping*/ #pragma warning( disable: 4152 )  /* function/data pointer conversion in expression */ #pragma warning( disable: 4100 ) /* unreferenced arguments in x86 call */  #pragma optimize("", off )   #define use_stubless_proxy   // verify <rpcproxy.h> version high enough compile file #ifndef __redq_rpcproxy_h_version__ #define __required_rpcproxy_h_version__ 475 #endif   #include "rpcproxy.h" #ifndef __rpcproxy_h_version__ #error stub requires updated version of <rpcproxy.h> #endif // __rpcproxy_h_version__    #include "xxx_i.h"  #define type_format_string_size   3                                  #define proc_format_string_size   1                                  #define expr_format_string_size   1                                  #define transmit_as_table_size    0             #define wire_marshal_table_size   0              typedef struct _xxx_midl_type_format_string     {     short          pad;     unsigned char  format[ type_format_string_size ];     } xxx_midl_type_format_string;  typedef struct _xxx_midl_proc_format_string     {     short          pad;     unsigned char  format[ proc_format_string_size ];     } xxx_midl_proc_format_string;  typedef struct _xxx_midl_expr_format_string     {     long          pad;     unsigned char  format[ expr_format_string_size ];     } xxx_midl_expr_format_string;   static const rpc_syntax_identifier  _rpctransfersyntax =  {{0x8a885d04,0x1ceb,0x11c9,{0x9f,0xe8,0x08,0x00,0x2b,0x10,0x48,0x60}},{2,0}};   extern const xxx_midl_type_format_string xxx__midl_typeformatstring; extern const xxx_midl_proc_format_string xxx__midl_procformatstring; extern const xxx_midl_expr_format_string xxx__midl_exprformatstring;   extern const midl_stub_desc object_stubdesc;   extern const midl_server_info iconnect_serverinfo; extern const midl_stubless_proxy_info iconnect_proxyinfo;    #if !defined(__rpc_win32__) #error  invalid build platform stub. #endif  #if !(target_is_nt50_or_later) #error need windows 2000 or later run stub because uses these features: #error   /robust command line switch. #error however, c/c++ compilation flags indicate intend run app on earlier systems. #error app fail rpc_x_wrong_stub_version error. #endif   static const xxx_midl_proc_format_string xxx__midl_procformatstring =     {         0,         {              0x0         }     };  static const xxx_midl_type_format_string xxx__midl_typeformatstring =     {         0,         {             ndrfcshort( 0x0 ),  /* 0 */              0x0         }     };   // object interface: iunknown, ver. 0.0,   guid={0x00000000,0x0000,0x0000,{0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x46}}    // object interface: idispatch, ver. 0.0,    guid={0x00020400,0x0000,0x0000,{0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x46}}     object interface: iconnect, ver. 0.0,   guid={0xdb80c724,0xa335,0x467e,{0x98,0x45,0x0b,0xd3,0x48,0x90,0xe4,0x63}}   #pragma code_seg(".orpc") static const unsigned short iconnect_formatstringoffsettable[] =     {     (unsigned short) -1,     (unsigned short) -1,     (unsigned short) -1,     (unsigned short) -1,     0     };  static const midl_stubless_proxy_info iconnect_proxyinfo =     {     &object_stubdesc,     xxx__midl_procformatstring.format,     &iconnect_formatstringoffsettable[-3],     0,     0,     0     };   static const midl_server_info iconnect_serverinfo =      {     &object_stubdesc,     0,     xxx__midl_procformatstring.format,     &iconnect_formatstringoffsettable[-3],     0,     0,     0,     0}; cinterface_proxy_vtable(7) _iconnectproxyvtbl =  {     0,     &iid_iconnect,     iunknown_queryinterface_proxy,     iunknown_addref_proxy,     iunknown_release_proxy ,     0 /* idispatch::gettypeinfocount */ ,     0 /* idispatch::gettypeinfo */ ,     0 /* idispatch::getidsofnames */ ,     0 /* idispatch_invoke_proxy */ };   static const prpc_stub_function iconnect_table[] = {     stub_forwarding_function,     stub_forwarding_function,     stub_forwarding_function,     stub_forwarding_function };  cinterfacestubvtbl _iconnectstubvtbl = {     &iid_iconnect,     &iconnect_serverinfo,     7,     &iconnect_table[-3],     cstdstubbuffer_delegating_methods };  static const midl_stub_desc object_stubdesc =      {     0,     ndroleallocate,     ndrolefree,     0,     0,     0,     0,     0,     xxx__midl_typeformatstring.format,     1, /* -error bounds_check flag */     0x50002, /* ndr library version */     0,     0x800025b, /* midl version 8.0.603 */     0,     0,     0,  /* notify & notify_flag routine table */     0x1, /* midl flag */     0, /* cs routines */     0,   /* proxy/server info */     0     };  const cinterfaceproxyvtbl * const _xxx_proxyvtbllist[] =  {     ( cinterfaceproxyvtbl *) &_iconnectproxyvtbl,     0 };  const cinterfacestubvtbl * const _xxx_stubvtbllist[] =  {     ( cinterfacestubvtbl *) &_iconnectstubvtbl,     0 };  pcinterfacename const _xxx_interfacenameslist[] =  {     "iconnect",     0 };  const iid *  const _xxx_baseiidlist[] =  {     &iid_idispatch,     0 };   #define _xxx_check_iid(n)   iid_generic_check_iid( _serversoftmail, piid, n)  int __stdcall _xxx_iid_lookup( const iid * piid, int * pindex ) {      if(!_xxx_check_iid(0))         {         *pindex = 0;         return 1;         }      return 0; }  const extendedproxyfileinfo xxx_proxyfileinfo =  {     (pcinterfaceproxyvtbllist *) & _xxx_proxyvtbllist,     (pcinterfacestubvtbllist *) & _xxx_stubvtbllist,     (const pcinterfacename * ) & _xxx_interfacenameslist,     (const iid ** ) & _xxx_baseiidlist,     & _xxx_iid_lookup,      1,     2,     0, /* table of [async_uuid] interfaces */     0, /* filler1 */     0, /* filler2 */     0  /* filler3 */ }; #pragma optimize("", on ) #if _msc_ver >= 1200 #pragma warning(pop) #endif   #endif // !defined(_m_ia64) && !defined(_m_amd64) && !defined(_arm_)    , xxx_i.c:    /* generated file contains iids , clsids */  /* link file in server , clients */    /* file created midl compiler version 8.00.0603 */ /* @ wed apr 29 16:19:24 2015  */ /* compiler settings xxx.idl:     oicf, w1, zp8, env=win32 (32b run), target_arch=x86 8.00.0603      protocol : dce , ms_ext, c_ext, robust     error checks: allocation ref bounds_check enum stub_data      vc __declspec() decoration level:           __declspec(uuid()), __declspec(selectany), __declspec(novtable)          declspec_uuid(), midl_interface() */ /* @@midl_file_heading(  ) */  #pragma warning( disable: 4049 )  /* more 64k source lines */   #ifdef __cplusplus extern "c"{ #endif    #include <rpc.h> #include <rpcndr.h>  #ifdef _midl_use_guiddef_  #ifndef initguid #define initguid #include <guiddef.h> #undef initguid #else #include <guiddef.h> #endif  #define midl_define_guid(type,name,l,w1,w2,b1,b2,b3,b4,b5,b6,b7,b8) \         define_guid(name,l,w1,w2,b1,b2,b3,b4,b5,b6,b7,b8)  #else // !_midl_use_guiddef_  #ifndef __iid_defined__ #define __iid_defined__  typedef struct _iid {     unsigned long x;     unsigned short s1;     unsigned short s2;     unsigned char  c[8]; } iid;  #endif // __iid_defined__  #ifndef clsid_defined #define clsid_defined typedef iid clsid; #endif // clsid_defined  #define midl_define_guid(type,name,l,w1,w2,b1,b2,b3,b4,b5,b6,b7,b8) \         const type name = {l,w1,w2,{b1,b2,b3,b4,b5,b6,b7,b8}}  #endif !_midl_use_guiddef_  midl_define_guid(iid, iid_iconnect,0xdb80c724,0xa335,0x467e,0x98,0x45,0x0b,0xd3,0x48,0x90,0xe4,0x63);   midl_define_guid(iid, libid_xxxlib,0xd6d698bd,0x4ad4,0x4908,0xbc,0x60,0x3e,0x1d,0xfb,0xc8,0x1d,0x59);   midl_define_guid(clsid, clsid_connect,0x3649cc04,0x53d0,0x4b48,0x82,0x92,0x25,0x00,0xfc,0x7d,0xd3,0xe3);  #undef midl_define_guid  #ifdef __cplusplus } #endif 

while creating atl simple object class,through wizard in vs2013, goto page selecting next till find

enter image description here

and select custom->automation compatible instead of dual. implement interface.it not give error


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -