<?xml version="1.0"?>
<!-- @ Copyright 1998-2003 W3C (MIT, ERCIM, Keio), All Rights Reserved. See http://www.w3.org/Consortium/Legal/. @ -->
<vxml version="2.0" xmlns="http://www.w3.org/2001/vxml"
      xmlns:conf="http://www.w3.org/2002/vxml-conformance">

<!--
    The value of the name attribute of a form item defines a
    dialog-scoped variable that holds the value of the form
    item, i.e., dialog.name is a reference to the form
    item variable.
-->

  <catch>
    <conf:comment>
      Toplevel caught event <value expr="_event"/>
    </conf:comment>
    <conf:fail expr="_event"/>
  </catch>


  <form id="first">
    <block>
      <if cond="dialog.a != undefined">
        <conf:fail reason="Form item variable must initially be undefined."/>
      </if>
    </block>

    <field name="a">
      <conf:speech value="alpha"/>
      <conf:grammar utterance="alpha" interp="alpha"/>
    </field>

    <block>
      <prompt> You said <value expr="dialog.a"/>. <break/>  You are perhaps surprised? </prompt>
      <if cond="dialog.a != 'alpha'">
        <conf:fail reason="Form item variable not set properly."/>
      </if>
      <conf:pass/>
    </block>
  </form>

</vxml>
