StartupTask class 无法识别

StartupTask class is not recognized

我正在尝试让我的 Centennial 应用程序在登录时自动启动。根据 that can be done. But then to disable it programmatically I'd need to use the Windows.ApplicationModel.StartupTaskclass和Visual Studio拒绝承认。那么 class 是如何使用的呢?

您需要添加对桌面扩展 SDK 的引用。