how to mask the full input but the last four number
See original GitHub issueI would like to mask all the numbers but the last two. Like the following example:
IN:
123451234
*****1234
12341234
****1234
I’ve tried the following unsuccessfully:
<input matInput
mask="\(X\)*0000"
[hiddenInput]="true"
<input matInput
mask="X*0000"
[hiddenInput]="true"
<input matInput
mask="X{,}0{4}"
[hiddenInput]="true"
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (1 by maintainers)
Top Results From Across the Web
Regex mask last 4 numbers - Stack Overflow
Your current regex matches any digit that doesn't have four other digits immediately following it. Which is the case for every digit in...
Read more >Control data entry formats with input masks - Microsoft Support
In the Field Properties area, click the Input Mask text box, and then type your custom mask. Press CTRL+S to save your changes....
Read more >Solved: Input mask apply flexibility in character numbers?
I have a field that would get input values of two to three letters followed by one to four digits. The letters need...
Read more >How to Use an Input Mask in Microsoft Access ... - YouTube
In this video, I will teach you how to use an Input Mask in your Microsoft Access tables and forms. We will create...
Read more >How to show only the last 4 digits of social security number ...
1. Select all cells containing social security numbers, then click Kutools > Text > Remove by Position. 2. In the Remove by Position...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@AlexeyDolya that works with a seven digit input. I mean, if you input
12345678
you get the expected last two numbers to be the only ones visibles.But, if you input a six o five digit number
12345
; you won’t get the expected behaviour; you wouln’t see the last two digits, it will be masked.The issue/improvment is to be able to apply mask from right to left, the same way is now working from left to right.
Not the best solution, but you can use OR statement for mask.
<input [hiddenInput]=“true” mask=“XXX00 || XXXX00 || XXXXX00”>