Warm tip: This article is reproduced from serverfault.com, please click

vb.net-开发应用程序的最低要求

(vb.net - Minimum requirements for developed application)

发布于 2020-11-27 19:28:33

我正在使用VS2019开发应用程序,并且正在编写使用它的用户指南。有没有办法查看运行我的应用程序的最低(也是推荐)硬件要求?我实际上使用的是4.7.2 .NET Framework版本。提前致谢。

Questioner
telemaco10399
Viewed
0
SteveCinq 2020-11-28 07:50:24

如果有任何用处(我认为是,请使用它们),可以使用两种方法来强制执行(或至少突出显示)依赖关系:

  1. app.manifest文件具有如部分
<!-- Enable the below block to check for dependencies. Application should not start if they are not found. -->
<dependency>
  <dependentAssembly>
    <assemblyIdentity name="Some.Assembly" version="1.2.3.4" type="win32" publicKeyToken="728fe7fe44de4b05"/>
    <publisherPolicy apply="no"/>
  </dependentAssembly>
</dependency>

你可以在其中添加先决条件。

清单还允许你设置与各种Windows版本的兼容性:

<!-- A list of all Windows versions that this application is designed to work with. Windows will automatically select the most compatible environment. -->
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
  <application>
    <!-- Windows Vista and Windows Server 2008 functionality -->
    <supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/>
    <!-- Windows 7 and Windows Server 2008 R2 functionality -->
    <supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>
    <!-- Windows 8 and Windows Server 2012 functionality -->
    <supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/>
    <!-- Windows 8.1 and Windows Server 2012 R2 functionality -->
    <supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/>
    <!-- Windows 10, Windows Server 2016 and Windows Server 2019 functionality -->
    <supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>
  </application>
</compatibility>

  1. 如果你的应用程序具有安装程序(setup.exe),则可以包括相关性(例如特定的.NET版本),库(例如SQL Server,C ++等):

在此处输入图片说明