locked
WinRT component to use legacy Win32 DLL

    Question

  • Hi,

    I'm working on a metro app in javascript + WinRT component + legacy Win32DLL. Win32DLL is compiled in VS2008. My WinRT component can link to the export lib of my Win32DLL project, however, when js codes try to create the WinRT object, the error says some module can not be found. I followed other forum thread to deploy all my DLL to the project folder and everything are there.

    the thing can only work if I compile my Win32DLL in VS2011 Exp, then it is fine.

    the question is, in the metro app package, all Win32DLL should be re-compiled in VS2011 Exp? Is that because all the Win32DLL and WinRT use the same version of runtime library? or, Win32 DLL is ok to use, just I did something wrong?

     

    Thanks.

    Thursday, January 19, 2012 12:23 AM

Answers

  • You understood right.  All binaries included inside your package need to be compiled with VS2011 so that they all depend only on the Dev11 C++ Runtime which will be present for the Metro style apps.  The runtimes for previous versions of VS will not be ported to work with Metro style apps.

    Thanks,


    Raman Sharma | Program Manager, Visual C++ | @rasharm_msft

    (if my post has answered your question, please consider using the 'mark as answer' feature in the forums to help others)
    • Marked as answer by alexhuang888 Thursday, January 19, 2012 5:22 PM
    Thursday, January 19, 2012 3:48 AM