title: Imported Type Library no longer working
body: <p>I have a large project in C++ Builder that seems to have used the function <em>Import Type Library</em>. In it is a file with a header like this</p>
  
  <pre><code>// ************************************************************************ //
  // WARNING                                                                    
  // -------                                                                    
  // The types declared in this file were generated from data read from a       
  // Type Library. If this type library is explicitly or indirectly (via        
  // another type library referring to this type library) re-imported, or the   
  // 'Refresh' command of the Type Library Editor activated while editing the   
  // Type Library, the contents of this file will be regenerated and all        
  // manual modifications will be lost.                                         
  // ************************************************************************ //
  
  // C++ TLBWRTR : $Revision:   1.134.1.41  $
  // File generated on 2003-10-27 12:57:05 from Type Library described below.
  
  // ************************************************************************ //
  // Type Lib: C:\WINNT\system32\MQOA.DLL (1)
  // IID\LCID: {D7D6E071-DCCD-11D0-AA4B-0060970DEBAE}\0
  // Helpfile: 
  // DepndLst: 
  //   (1) v2.0 stdole, (C:\WINNT\System32\stdole2.tlb)
  //   (2) v4.0 StdVCL, (C:\WINNT\System32\STDVCL40.DLL)
  // ************************************************************************ //
  #ifndef   __MSMQ_OCX_h__
  #define   __MSMQ_OCX_h__
  
  #pragma option push -b -w-inl
  
  #include &lt;utilcls.h&gt;
  #if !defined(__UTILCLS_H_VERSION) || (__UTILCLS_H_VERSION &lt; 0x0500)
  //
  // The code generated by the TLIBIMP utility or the Import|TypeLibrary 
  // and Import|ActiveX feature of C++Builder rely on specific versions of
  // the header file UTILCLS.H found in the INCLUDE\VCL directory. If an 
  // older version of the file is detected, you probably need an update/patch.
  //
  #error "This file requires a newer version of the header UTILCLS.H" \
         "You need to apply an update/patch to your copy of C++Builder"
  #endif
  #include &lt;olectl.h&gt;
  #include &lt;ocidl.h&gt;
  #if !defined(_NO_VCL)
  #include &lt;stdvcl.hpp&gt;
  #endif  //   _NO_VCL
  #include &lt;ocxproxy.h&gt;
  
  ...
  </code></pre>
  
  <p>As you can see this file was genereated quite long time ago :). I have been able to build this project using <strong>C++ Builder 2010</strong> on <strong>Windows 7 64-bit</strong>. But when I install <strong>XE2</strong> and try to fix all the small issues that arise since it now defaults to <strong>STRICT</strong> instead of <strong>NO_STRICT</strong>, I run into a totaly different issue. The above file, ad others generated in the same way, they no longer work as intended.</p>
  
  <p>I get errors like </p>
  
  <blockquote>
    <p>[BCC32 Error] MSMQ_OCX.h(66): E2090 Qualifier 'Oleserver' is not a
    class or namespace name</p>
  </blockquote>
  
  <p>Looking for the <strong>MQOA.DLL</strong> it claims to have used nothing of the sort seems to exist. Does anyone have any pointers on how to get around these kind of problems when updating the project to XE2? The project has survived upgrades before and was lastley upgraded to C++ Builder 2010. But I'm more of a Visual Studio person so a lot of the Embarcadero stuff is new territory.</p>