SUMMARY
Advanced: Requires expert coding, interoperability, and multiuser skills.
This article shows you how to create a sample Microsoft Access function
called RemoveAlphas() to remove alpha, or nonnumeric, characters from an
alphanumeric string. All nonnumeric characters will be removed.
A common use for the RemoveAlphas() function is to remove the parentheses,
dashes, and spaces from a telephone number or social security number field.
The following strings contain parentheses, dashes, and spaces:
"(206) 635-7050"
"206-635-7050"
"535-87-4529"
After the RemoveAlphas() function is run, these strings will be:
"2066357050"
"2066357050"
"535874529"
This article assumes that you are familiar with Visual Basic for
Applications and with creating Microsoft Access applications using the
programming tools provided with Microsoft Access. For more information
about Visual Basic for Applications, please refer to your version of the
"Building Applications with Microsoft Access" manual.
NOTE: Visual Basic for Applications is called Access Basic in Microsoft
Access versions 1.x and 2.0. For more information about Access Basic,
please refer to the "Introduction to Programming" manual in Microsoft
Access version 1.x or the "Building Applications" manual in Microsoft
Access version 2.0