Last Four Digit of SSN(Social Security Number).

vishalneeraj-24503
Posted by vishalneeraj-24503 under ASP.NET category on | Points: 40 | Views : 8876
For Security purpose,we also have to hide SSN number or Masked
Below property will be used for masking first 5 digit of SSN as X and showing Last four digit.
public string LAST_FOUR_DIGIT_SSN
{
get
{
string LastFourDigitSSN = ssn.Substring(5, 4);
return "XXX-XX-" + LastFourDigitSSN;
}
}

Use it any where on the page.

Comments or Responses

Login to post response