Cortana apps and voice commands not showing or working from Cortana

App commands and voices don't appear in Cortana when you type "what can I say?"

I am trying to use voice commands in Foreground with Cortana and running the sample Cortana Voice Command and have been unable to get Cortana to show the app or open / execute voice commands for an app called "AdventureWorks".

I am using Cortana Voice Command Sample, which I run from Visual Studio 2015 locally on Windows 10 in debug. According to this link, this should create an unpacked version of the sample on my local machine, which I should see on the start screen, which I can't. I activated the microphone under the app capabilities and included the en.-RU resource file and changed the Package.appxmanifest to the default en-GB language to match to make sure the Cortana language matches the app to fix that as a potential issue.

Here is a link showing the unpackaged version of the app should show up on the Start screen after launching the app from VS (with or without debugging): How do I install a Metro app on my desktop?

Cortana Voice Commands Example: https://github.com/Microsoft/Windows-universal-samples/tree/master/Samples/CortanaVoiceCommand

Note: The app is standard except for me, including the en-GB resource file, changing the location of package.appxmanifest to en-GB and adding Microphone to the app's capabilities. Developer mode is also enabled on my computer.

Update: No exceptions occur when adding vcd.xml to VoiceCommandDefinitionManager. It looks like it should work. I also noticed that when running the sample, I do not see the London image or the microphone icon saying "listening" as in this video: https://channel9.msdn.com/Events/Build/2015/3-716 at 04:16

Google searches for "app not showing in Cortana" are currently not showing useful results.

Anyone else have any luck to get this sample to work? or similar questions? Also are you using the en-GB version?

Any help or ideas would be appreciated

+3


source to share


3 answers


I have successfully tested the AdverntureWorks sample using en-US. I also developed another sample regarding Cortana Foreground.

Basically I created a VCD and then installed it:

protected async override void OnLaunched(LaunchActivatedEventArgs e)
{
    ...
    // Install the VCD
    try
    {
        StorageFile vcdStorageFile = await Package.Current.InstalledLocation.GetFileAsync(@"HomeControlCommands.xml");
        await VoiceCommandDefinitionManager.InstallCommandDefinitionsFromStorageFileAsync(vcdStorageFile);
    }
    catch (Exception ex)
    {
        System.Diagnostics.Debug.WriteLine("There was an error registering the Voice Command Definitions", ex);
    }
}

      



And then processed the activation:

protected override void OnActivated(IActivatedEventArgs e)
{
    // Handle when app is launched by Cortana
    if (e.Kind == ActivationKind.VoiceCommand)
    {
        VoiceCommandActivatedEventArgs commandArgs = e as VoiceCommandActivatedEventArgs;
        SpeechRecognitionResult speechRecognitionResult = commandArgs.Result;

        string voiceCommandName = speechRecognitionResult.RulePath[0];
        string textSpoken = speechRecognitionResult.Text;
        IReadOnlyList<string> recognizedVoiceCommandPhrases;

        System.Diagnostics.Debug.WriteLine("voiceCommandName: " + voiceCommandName);
        System.Diagnostics.Debug.WriteLine("textSpoken: " + textSpoken);

        switch (voiceCommandName)
        {
        ...
        }
    }
}

      

The detailed process is described here

+1


source


I had exactly the same problem.

Make sure you have the microphone capability for yours Package.appxmanifest

, otherwise it won't work.

Tu enable it, select Package.appxmanifest

in solution explorer, go to Capabilities

and check Microphone

.



More information: http://jamescroft.co.uk/blog/universal-windows-8-dev/how-to-get-your-apps-cortana-ready/

Hope this helps, damtur

+1


source


I had the same problem as you, as DevEnitly pointed out, if your region is set to UK for example and in your VCD file your CommandSet language is en-US it won't work just by changing the CommandSet language to us -gb (or whichever language suits your region) should do the trick (it did for me), also note that if you want to support different languages ​​you have to add more CommandSets. Hope this solves your problems.

+1


source







All Articles