WindowsCommunityToolkit icon indicating copy to clipboard operation
WindowsCommunityToolkit copied to clipboard

extensions:TextBoxRegex.ValidationType="Number" in UWP, still taking whitespaces after a single number entered, why?

Open sharathcng opened this issue 1 year ago • 28 comments

In UWP windows app, I have used this extensions:TextBoxRegex.ValidationMode="Dynamic" extensions:TextBoxRegex.ValidationType="Number" to dynamically remove whitespaces, letters and any special characters dynamically. Initially it's not allowing whitespaces but after entering a single digit it's taking whitespaces. Can anyone help me with this issue? <TextBox Grid.Row="0" Grid.Column="2" HorizontalAlignment="Stretch" extensions:TextBoxRegex.ValidationMode="Dynamic" extensions:TextBoxRegex.ValidationType="Number" IsEnabled="{Binding IsDataPresent, Mode=TwoWay}" Style="{StaticResource FieldValueCommonTextBoxStyle}" Text="{Binding DeliveryDocInputHeader.DELIVERY_NO, Mode=TwoWay}" />

sharathcng avatar Jan 18 '23 12:01 sharathcng