<help>

Catches the event generated when the caller says “help”. The Voice Browser service provides access to three JavaScript variables within the <catch> element:

  • _event—Specifies the name of the event that was caught.
  • _message—Specifies a message that describes the event that was caught.
  • _exception (Nuance extension)—Specifies the exception that caused the event to be generated.

The <help> element provides a shorthand notation for <catch event="help">.

See <catch>, <error>, <noinput>, and <nomatch> for descriptions of similar event-catching elements.

Attributes

This section describes the attributes you can set for this element.

Name

Data type

Default

cond

CDATA

optional

count

CDATA

optional

cond

The cond attribute specifies a Boolean expression. This Boolean expression must evaluate to true before the <catch> element is available for selection within the Form Interpretation Algorithm (FIA).

count

The count attribute (default is 1) specifies the minimum number of specified event occurrences that must take place before the handler is available for selection in the Form Interpretation Algorithm (FIA). The selected handler is the one with the highest count value.

Each <clear>, <form> and <menu> element, as well as each form item maintains a counter for each event that occurs while it is being visited. These counters are reset each time the <menu> element or form item's <form> element is re-entered. The form-level counters are used in the selection of an event handler for events thrown in a form-level <filled> element.

Note: Counters are incremented against the full event name and every prefix matching event name. For example, occurrence of the event "event.foo.1" increments the counters associated with handlers for "event.foo.1", "event.foo", and "event".

Children

Parents

Sample code

<prompt>Who goes there?</prompt>
<help>
<prompt>hint: you are the king.</prompt>
<reprompt/>
</help>
</field>
<field name="swallow">
<prompt>What is the average wind speed velocity of an unladen
swallow?</prompt>
<catch event="help">
<prompt>hint: it depends where the bird comes from.</prompt>
<reprompt/>
</catch>
</field>
<noinput>
<prompt>sorry, i didn't catch that.</prompt>
<reprompt/>
</noinput>
<nomatch>
<prompt>no, sorry, that's not it. try again.</prompt>
</nomatch>
<error>
<log expr="'Error processing bridge sequence. and now for something completely different.../>
<throw event="SOMETHING_COMPLETELY_DIFFERENT"/>
</error>
<filled>You may pass.</filled>
</form>