locked
adding a command to a sequence dynamically RRS feed

  • Question

  •  

    Hello,

    We need to be able to add a command activity to a speech sequence at runtime (dynamically). We are getting an exception when we try to do this and want to see if this is something that is allowed (possible). We don't know what, or how many, commands will be added until the application starts running. If there is no way to do this, and you say, 'well add all possible commands up front (during app initialization), then would we be able to set the properties of these commands at runtime? For example, could we dynamically set the grammars for the command and I guess the activites that are executed if the command fires? If this is still not possible, is there any way to accomplish this doing some custom coding, using the base (core) API?

    Thank you,

    Mike

     

    Friday, March 21, 2008 11:34 PM

All replies

  •  

    You cannot dynamically modify the workflow. However you can dynamically update the grammar or create grammar for your commands at runtime. If these commands are generic commands (not the specific ones like RepeatCommands) then have you looked at having just one command activity and adding all the response phrases into grammar of that one command. After the command fires you can query the command's RecognitionResult to find out which command the user wanted.

     

    Thanks!

    Vishwa

     

    [This posting is AS IS and does not confer to any rights]

    Monday, March 24, 2008 11:56 PM