Jump to content
Sign in to follow this  

ss# and Phone#

Recommended Posts

again a beginner's question????

good methods to force a ###-##-#### for SSN and ###-###-#### for phone numbers on layout

i'm sure you all have a bunch of answers, but i am a beginner

i thank you in advance

Share this post

Link to post
Share on other sites

I put 2 fields on top of each other...

top field with opaque background, not selectable in browse mode to display

the result (say a text field with a calculation that formats the phone number

like you want wtih the "(" etc.).

an the bottom field (a number only field) to take the user input in browse mode.

Base on what the user enters your calculated top field will convert and display

in the desired color & format all based on your calculation.

Good luck


Share this post

Link to post
Share on other sites

With 7 you can now have an auto enter calcualted field that will update after the first instance of entering. This enables you to reformat a field to whatever you wish it to contain.

This is great for phone number and social security formatting amongst other things.

Simply create a text field for your phone number and then apply an auto enter calculation, something along the lines of:

    /* The Let () function allows us to create a variable for use within a calculation */

Let (

 [  PhoneNumber=Filter ( Current Field Name Here; "0123456789") ];

      /* The filter removes all extra characters, leaving just the numbers */ 

      /* Reformat the number now, adding in the extra characters */

   Left(PhoneNumber; 3) & "-" & Middle(PhoneNumber; 4; 3) & "-" & Right(PhoneNumber; 4)


After you click ok, uncheck the box underneath the auto enter calc value so that the field will update itself when the contents are changed.

This now saves on any extra "display" fields and the user does not get confused when they click in the field and the format changes. They can enter the phone number how ever they want, but it will update to your format when they leave the field. If they click back in the field, what they see is what they get.

Share this post

Link to post
Share on other sites

Thanks Andy,

my solutions was based on FM 5.5, I will look into your idea for my new design!


Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this  


Important Information

By using this site, you agree to our Terms of Use.