CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Apr 1999
    Posts
    30

    compiler support for importing typelibs

    When using #import *.tlb with VC++ 5.0 and VC++ 6.0, the two compilers create different signatures for the generated interface member functions that return IDispatch pointers. The 5.0 compiler returns an IDispatch* while the 6.0 compiler returns IDispatchPtr (a "smart" pointer).

    Is there a way to force the 5.0 compiler to return smart pointers in these cases too? This is causing a big pain in my development since I have to keep two different sets of source because of this.


  2. #2
    Join Date
    Apr 1999
    Posts
    15

    Re: compiler support for importing typelibs

    Hi
    you could write a #define definition which creates IDispatch* or IDispatchPtr depending on the compiler version.
    Julius Ivanyi


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured