Log In
Developer Network
Technologies
Join the Network
Member Services
Events & Community
Customer Voice Portal (CVP) Developer Center
Overview
Documentation
Community
Wiki
Message Boards Home
Recent Posts
Statistics
Answer
(
Unmark
)
Mark as an Answer
« Back to CVP - All Versions
Inputmode in custom Form element
Threads [
Previous
|
Next
]
Arvand Owji
Posts:
33
Join Date:
12/6/08
Recent Posts
Inputmode in custom Form element
Answer
8/26/10 7:01 PM
Mark as an Answer
Submit
Reply with Quote
Quick Reply
Hi,
I have a custom element that extends a form element and has a DTMF grammar and a voice grammar. I want to see what the input mode is when the return value is a nomatch. The reason is that i need to update some variables based on if the user had tried the voice grammar or if they have tried the dtmg grammar. I checked reqparamaters and ved but on a nomatch event, they dont hold anything that can give away the inputmode. Any suggestion on how I can get this? Thanks.
Sign in to vote.
Flag
Please sign in to flag this as inappropriate.
Top
Hemal Mehta
Posts:
525
Join Date:
11/27/08
Recent Posts
RE: Inputmode in custom Form element
Answer
8/27/10 2:45 AM as a reply to Arvand Owji.
Mark as an Answer
Submit
Reply with Quote
Quick Reply
Try using:
application.lastresult$[0].inputmode
Sign in to vote.
Flag
Please sign in to flag this as inappropriate.
Top
Hemal Mehta
Posts:
525
Join Date:
11/27/08
Recent Posts
RE: Inputmode in custom Form element
Answer
8/27/10 2:45 AM as a reply to Hemal Mehta.
Mark as an Answer
Submit
Reply with Quote
Quick Reply
That can be used in the vxml code
Sign in to vote.
Flag
Please sign in to flag this as inappropriate.
Top
Arvand Owji
Posts:
33
Join Date:
12/6/08
Recent Posts
RE: Inputmode in custom Form element
Answer
8/27/10 5:25 PM as a reply to Hemal Mehta.
Mark as an Answer
Submit
Reply with Quote
Quick Reply
Try using:
application.lastresult$[0].inputmode
Thanks for the suggestion but as you said it in the next post, it can only be used in the VXML. I need to do the samething in a custom form element for when a nomatch happens...
Sign in to vote.
Flag
Please sign in to flag this as inappropriate.
Top
Janine Graves
Posts:
1306
Join Date:
5/2/08
Recent Posts
Re: New Message from Arvand Owji in Customer Voice Portal (CVP) - CVP - All
Answer
8/27/10 11:36 PM as a reply to Arvand Owji.
Mark as an Answer
Submit
Reply with Quote
Quick Reply
First you have to determine whether Cisco fills in the shadow variable
application.lastresult$[0].inputmode upon a nomatch.
The VoiceXML 2.0 Specification says "All of the shadow variables are set
immediately after any recognition. In this context, a <nomatch> event
counts as a recognition, and causes the value of
"application.lastresult$" to be set, though the values stored in
application.lastresult$ are PLATFORM DEPENDENT"
Can anyone at Cisco answer that question?
Then you'd need to extend the Form element's java class to include the
passing back of that variable. You'd do this by modifying the
addXmlBody() method calling super.addXmlBody(); adding some VFCs to
create a new variable 'nomatch_inputmode'; assign it the value
application.lastresult$[0].inputmode into the 'nomatch_inputmode'
variable; and then return 'nomatch_inputmode' as part of the <submit>
from the gateway to VxmlServer.
On 8/27/2010 8:25 AM, Cisco Developer Community Forums wrote:
> Arvand Owji has created a new message in the forum "CVP - All Versions":
>
> --------------------------------------------------------------
> Try using:
> application.lastresult$[0].inputmode
>
>
> Thanks for the suggestion but as you said it in the next post, it can
> only be used in the VXML. I need to do the samething in a custom form
> element for when a nomatch happens...
> --
> To respond to this post, please click the following link:
>
> <http://developer.cisco.com/web/cvp/forums/-/message_boards/message/2483270>
>
> or simply reply to this email.
--
Janine Graves
781-990-1040
Sign in to vote.
Flag
Please sign in to flag this as inappropriate.
Top