Share via


AllowVISA Property for French (Canada)

  Microsoft Speech Technologies Homepage

Gets or sets whether the control accepts VISA account numbers. Read/write.

Usage

ASP.NET markup: <speech:CreditCardNumber AllowVISA="..." />
Get value: String = CreditCardNumber.AllowVISA;
Set value: CreditCardNumber.AllowVISA = String;
Data type: String
Required: No; Default: True

Remarks

The AllowAmex, AllowDinersClub, AllowDiscover, AllowMasterCard, and AllowVISA properties specify the credit card types that the CreditCardNumber control accepts. At least one of these properties must be true, that is, the control must accept at least one type of credit card, or the control throws an exception.

If only one type of credit card is accepted, the CreditCardNumber control begins execution by playing the text of the QuestionPrompt property, which asks the user for the credit card number. If more than one type of credit card is accepted, the control begins execution by asking the user for the credit card type, and then plays the QuestionPrompt text.

Example

The following example is adapted from the Microsoft Speech Application SDK Credit Card sample.

<form id="Form1" method="post" runat="server">
  ...
  <speech:SemanticMap ID="CCSemanticMap" runat="server">
    <speech:SemanticItem ID="siCCNumber" 
      TargetElement="tbCCNumber" TargetAttribute="value"
      SensitiveData="True">
    </speech:SemanticItem>
    <speech:SemanticItem ID="siCCMonth" runat="server"
      TargetElement="tbCCMonth" TargetAttribute="value">
    </speech:SemanticItem>
    <speech:SemanticItem ID="siCCYear" runat="server"
      TargetElement="tbCCYear" TargetAttribute="value">
    </speech:SemanticItem>
  </speech:SemanticMap>

  <speech:CreditCardNumber 
    ID="GetCreditCardNumber" 
    SemanticItem="siCCNumber"
    QuestionPrompt="rentrer les 16 chiffres de votre numéro de carte de crédit visa s'il-vous-plaît" 
    AllowAmex="False"
    AllowDinersClub="False" 
    AllowDiscover="False" 
    AllowMasterCard="False"
    AllowVISA="True" 
    EnableViewState="False" 
    runat="server">
  </speech:CreditCardNumber>

  <speech:CreditCardDate 
    ID="GetCreditCardDate"     
    QuestionPrompt="What is the expiration date?" 
    MonthSemanticItem="siCCMonth"
    YearSemanticItem="siCCYear"
    runat="server">
  </speech:CreditCardDate>

  <asp:TextBox ID="tbCCNumber" runat="server"></asp:TextBox>
  <asp:TextBox ID="tbCCMonth"  runat="server"></asp:TextBox>
  <asp:TextBox ID="tbCCYear"   runat="server"></asp:TextBox>
  ...
</form>

See Also

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