ClickOnce: getting MSVCRT C++ DLLs on user's machine

I've been trying desperately to get my application (15 C# dlls and 1 C++/CLI dll with C++ Runtime DLL dependencies) to deploy with ClickOnce. I got it to work by just copying the Release folder, but ClickOnce refuses to copy the files (msvcm80.dll, msvcp80.dll and msvcr80.dll) and deploy them in this folder.

I did this nutty workaround (supply msvcm80.dll, msvcp80.dll and msvcr80.dll as Content/Copy If Newer and then at startup, create the Microsoft.VC80.CRT folder, copy those DLLs, and create Microsoft.VC80.CRT.manifest) that seems to work, but this all just feels wrong to me.

Am I missing something?


I'm stupid: I just found this:

On Publish tab of Properties page of my startup project: click Prerequisites... button > check Visual C++ Runtime Libraries, radio button setting: Download prerequisites from the component vendor's web site.

It seems to work the way one might expect!


There should be a msi from microsoft that deploys those for you. I used....

instructions

and download vcredist_x86.exedownload

链接地址: http://www.djcxy.com/p/65984.html

上一篇: ClickOnce&References

下一篇: ClickOnce:在用户的机器上获取MSVCRT C ++ DLL