问题标签 [setup.exe]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
0 回答
19 浏览

c# - 强制以管理员身份运行的自动运行应用程序

我构建了一个 Windows 窗体设置应用程序(.exe)并强制以管理员身份运行。

我想在 Windows 启动时自动运行这个应用程序。为此,我将以下代码添加到我的程序中。

现在我的问题是当我删除以管理员身份运行的限制时,我的应用程序在 Windows 启动时自动运行。但是当我的应用程序被迫以管理员身份运行时,我的应用程序不会自动运行。我该如何解决这个问题?谢谢。