I have the following string: "10222002750400447092095835"
I want it to be displayed like this: 10 2220 0275 0400 4470 9209 5835
I tried doing the following, with no result at all:
[DisplayFormat(DataFormatString = "{0:00 0000 0000 0000 0000 0000 0000}", ApplyFormatInEditMode = true)]
or
[DisplayFormat(DataFormatString = "{0:## #### #### #### #### #### ####}", ApplyFormatInEditMode = true)]
What am I doing wrong?
I believe what you are looking for is String masking. See below.
Stackoverflow - How to mask a string Stackoverflow - Apply mask to string
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With