Ticket Q336723
Visible to All Users

masked textbox

created 14 years ago

Hi,
using the masked textbox , is it possible to use a mask that would allow only ascii characters as input?
if so can you help me with mask please.
Thanks

Show previous comments (22)
DevExpress Support Team 13 years ago

    Hi Shivangi,
    Thank you for your response and providing the additional explanation.
    I now understand what functionality you wish to see, and I suggest that you set the editor's MaskType property value to "DateTimeAdvancingCaret" and enable the ValidateOnTextInput option:

    XAML
    <dxe:DateEdit Width="150" Margin="10" Name="dt1" MaxValue="{x:Static Member=sys:DateTime.Now}" MinValue ="1/1/1910" DisplayFormatString="d" ValidateOnTextInput="True" MaskType="DateTimeAdvancingCaret"> <dxe:DateEdit.ErrorToolTipContentTemplate> <DataTemplate> <TextBlock x:Name="txtmsg"> <TextBlock.Text> <MultiBinding Converter="{StaticResource ErrorTooltipTextConverter}"> <Binding Path="MinValue" RelativeSource="{RelativeSource Mode=FindAncestor, AncestorType=dxe:DateEdit}"/> <Binding Path="MaxValue" RelativeSource="{RelativeSource Mode=FindAncestor, AncestorType=dxe:DateEdit}"/> </MultiBinding> </TextBlock.Text> </TextBlock> </DataTemplate> </dxe:DateEdit.ErrorToolTipContentTemplate> </dxe:DateEdit>

    This way, the cursor will automatically jump to the next part of a date once you finish typing, which will force validation.
    Thanks,
    Vito

      Hi Vito,
      Thank you very much!!!
      Its really helped!!!
      Thanks
      Shivangi

      DevExpress Support Team 13 years ago

        I am glad to hear that this helped!
        Thanks,
        Vito

        Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

        Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.