首页 > 编程知识 正文

vs怎么附加数据库(vs附加包含目录)

时间:2023-05-04 06:26:20 阅读:75613 作者:4737

事由是通过GetVersionEx获取Win10版本号,获取出来是6.2,显然是错误的,需要附加一个manifest文件。
manifest文件内容如下,文件为UTF8编码:

<?xml version="1.0" encoding="UTF-8"?> <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0"> <compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1"> <application> <!-- Windows 10 --> <supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/> <!-- Windows 8.1 --> <supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/> <!-- Windows Vista --> <supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/> <!-- Windows 7 --> <supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/> <!-- Windows 8 --> <supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/> </application> </compatibility></assembly>

附加manifest文件的具体操作如图:

manifest文件要放到代码文件的根目录,即与vcxproj文件同级,重新编译项目即可,

版权声明:该文观点仅代表作者本人。处理文章:请发送邮件至 三1五14八八95#扣扣.com 举报,一经查实,本站将立刻删除。