Share via


OnClientActive Property for French (Canada)

  Microsoft Speech Technologies Homepage

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

Usage

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

Remarks

The value of the OnClientActive 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, after the QA control has been activated and before processing the QA (for example, playing a prompt or starting recognition).

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.OnClientActive
}

Parameters

None.

Return Value

None.

Example

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

<script>
  function myClientActive() {
    // OnClientActive 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" 
    OnClientActive="myClientActive"
    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