General information
Category:
Forms & Form designer
Environment versions
Network:
Windows 2003 Server
>Anyone have any ideas on how to display the last 4 digits of the SSN in a textbox and still store the complete number? We have the SSN in the database but management wants to mask it like this:
>
>***-**-1234.
Use a standard text box. Store the true value 123-45-6789 in the Tag property (with or without the dashes). For display set the textbox Value property to the Tag property:
this.Value = "***-**-" + RIGHT(this.Tag,4)
When a user edits the field (has the proper security to edit), then they would enter as normal (this way they can see that they are entering it correctly). Then in the Valid() event, set the Value property to the mask above. You can check the format to verify the correct input and then store to the Tag the true value and replace the Value property with the masked value.
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only