Partilhar via


OnClientListening Property for French (Canada)

  Microsoft Speech Technologies Homepage

Gets or sets the OnClientListening property of QA controls that are created by the control. Read/write.

Usage

ASP.NET markup: <speech:ApplicationControl OnClientListening="..." />
Get value: String = ApplicationControl.OnClientListening;
Set value: ApplicationControl.OnClientListening = String;
Data type: String
Required: No

Remarks

The value of the OnClientListening property is the name of a custom client-side script function, without parameters or parentheses. The client-side dialog manager calls this function, using the following syntax.

The script block that contains this function should be placed before the control that calls the function. For more information, see "Placement of Script Blocks" in Authoring Notes.

Syntax

string FunctionName ()
{
// Client-side code referenced by ApplicationControl.OnClientListening
}

Parameters

None.

Return Value

None.

Example

The following example demonstrates the OnClientListening property that is used in a Date Application Speech Control.

<script>
  function myClientListening() {
    // OnClientListening routine
    return true;
  }
</script>

<form id="Form1" method="post" runat="server">
  ...
  <speech:Date 
    id="Date1" 
    QuestionPrompt="quand est-ce que vous aimeriez voyager?" 
    DateContext="Future"
    AllowHolidays="True"
    AllowNumeralDates="True"
    AllowRelativeDates="True"
    DaySemanticItem="DaySemItem" 
    MonthSemanticItem="MonthSemItem"
    YearSemanticItem="YearSemItem" 
    ConfirmThreshold="0.6" 
    OnClientListening="myClientListening"
    runat="server">
  </speech:date>

  <asp:textbox id="tbDay" runat="server"></asp:textbox>
  <asp:TextBox id="tbMonth" runat="server"></asp:TextBox>
  <asp:TextBox id="tbYear" runat="server"></asp:TextBox>
  ...
</form>

See Also

ApplicationControl Class | ApplicationControl Constructor | ApplicationControl Members | ApplicationControl Properties | ApplicationControl Methods | ApplicationControl Events | ApplicationControl Remarks