在windows 7 x64上编译的.net framework 4.5程序,使用InstallShiled打包以后安装到windows 8 && 8.1后出现 “An app on your PC needs the following Windows feature: .NET Framework 3.5 (includes .NET 2.0 and 3.0)” 的提示。 因为在windows8上默认只安装有.net framework 4.0 4.5,没有使用CLR 2.0的framework 2.0 3.0 3.5,而4.x使用的全新的CLR 4.0. 根据 how-to-solve-an-app-on-your-pc-needs-the-following-windows-feature-net-framework-3-5-includes-net-2-0-and-3-0-on-windows-8 这篇文章中提到相关资料,在exe.config中添加: