Brian Dunning's FileMaker Custom Functions

StripCharacters ( field )

Removes formatted characters from a phone number

  Average rating: 4.6 (20 votes) Log in to vote

Michael Rocharde   Michael Rocharde
Ad-Minimum
http://www.michaelrocharde.com

Share on Facebook Share on Twitter

  Sample input:
(970) 728-3819
  Sample output:
9707283819

  Function definition: (Copy & paste into FileMaker's Edit Custom Function window)

Sending out SMS messages from FileMaker, using the HTTP Post function and a Twilio account is very easy but you need to have the cell phone number stripped down to 10 characters. This function removes the normal characters found in a formatted phone number.

 

Comments

Hisc   Hisc, noplace
Oct 12, 2015
Why not just use Filter ( text ; "0123456789" ) ? I ran some test and Substitute seems to be (insignificantly) slower. Also, Filter would be less error prone if all you need is the numbers.
 
Michael Rocharde   Michael Rocharde, Denver, CO
Oct 12, 2015
That's a very good point. I should have thought of using Filter. Thanks.
 

Log in to post comments.

 

Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.

Under construction. Email me your wish list for improvements.