首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >无法安装VCD文件

无法安装VCD文件
EN

Stack Overflow用户
提问于 2016-06-14 16:27:42
回答 1查看 168关注 0票数 0

我正试图将Cortana融入我的UWP。第一步是“安装”VCD文件。下面的代码片段在Windows 10上运行良好,但在部署到Xbox时会导致错误。具体来说,"installCommandDefinitionsFromStorageFileAsync“是失败的原因。还有其他方法在Xbox上安装VCD吗?或者,这是一个尚未修复的bug吗?

代码语言:javascript
复制
return wap.current.installedLocation.getFileAsync("vdmvoicecommands.xml").then(function (file) {
           return voiceCommandManager.installCommandDefinitionsFromStorageFileAsync(file);
       }, function (er) {
           console.error('error file vdmvoicecommands.xml', er);
       }).then(function () {
           var language = window.navigator.userLanguage || window.navigator.language;

           var commandSetName = "VDM_" + language.toLowerCase();

           var commansets = Windows.ApplicationModel.VoiceCommands.VoiceCommandDefinitionManager.installedCommandDefinitions;
           if (commansets.hasKey(commandSetName)) {
               console.log("VCD loaded !");
           } else {
               console.log("VCD not installed yet?");
           }
       }, function (ee) {
           console.warn("installCommandDefinitionsFromStorageFileAsync error", ee);
       });
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2016-06-16 21:39:39

Xbox目前不支持VoiceCommands API。您可以找到Xbox 这里目前不支持的UWP API列表。

票数 2
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/37817468

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档