首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Windows 10搜索API

Windows 10搜索API
EN

Stack Overflow用户
提问于 2015-10-29 03:29:32
回答 1查看 899关注 0票数 1

我希望用户能够在Windows10搜索框中输入产品id,让它显示网络数据库中的产品列表,然后当他们点击该产品id时,让它从我们的内部网加载一个网页。这个是可能的吗?我是否需要在计算机上安装一个桌面应用程序,以便Cortana进行搜索?

EN

回答 1

Stack Overflow用户

发布于 2015-10-29 05:49:27

您需要使用VCD文件创建一个UWP应用程序,您需要在其中设置Cortana如何调用您的应用程序。如果您应用程序名为"find it“或其他名称,那么您可以告诉cortana,每当有人在其搜索框中说或键入"find it”时,“她”必须调用您的应用程序,并将"find it“后面的内容作为参数。

代码语言:javascript
复制
        if (eventObject.detail.kind === Windows.ApplicationModel.Activation.ActivationKind.voiceCommand) {
        var speechRecognitionResult = eventObject.detail.result;

        // Get the name of the voice command. 
        // For this example, we declare only one command.
        var voiceCommandName = speechRecognitionResult.rulePath[0];

        // Get the actual text spoken.
        var textSpoken = speechRecognitionResult.text !== undefined ? speechRecognitionResult.text : "EXCEPTION";
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/33399940

复制
相关文章

相似问题

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