我正在开发一款Windows 10应用程序。Windows10应用程序的新功能之一是能够支持同一应用程序的多个实例(窗口)。我想禁用它。有没有人找到关于这个场景的文档?
发布于 2017-01-05 02:24:01
您可以在App.xaml.cs中覆盖方法OnLaunch:
protected async override void OnLaunched(LaunchActivatedEventArgs e)
{
if (e.PreviousExecutionState != ApplicationExecutionState.Running) //Check if is there any instance of the App is already running
{
base.OnLaunched(e);
}
}发布于 2015-06-19 04:34:04
在清单文件中查看此实例化属性。
https://stackoverflow.com/questions/30923809
复制相似问题