Avatar of Laura Sheldon
Laura SheldonFlag for United States of America

asked on 

Access 2007, input mask

Is it possible to use an input mask in an "Iif" function in a query to return the following:

A phone number with an extension or one w/o.

123-456-7891, Ext 1234

If applying the input mask using the properties window, I get the following:

(222-333-4444) = (   )  22-2333, Ext. 4444
(222-333-4444, Ext. 555) = (222) 333-4444, Ext. 555

* The Phone and Extension fields are in separate and joined with the following:
Fee Billing Phone: ([ClientPhone] & IIf([ClientExtension] Is Not Null,", " & [ClientExtension]))
Microsoft Access

Avatar of undefined
Last Comment
Jeffrey Coachman
Avatar of Laura Sheldon
Laura Sheldon
Flag of United States of America image

ASKER

Also, this is the IM I'm using on this field:
!\(###") "###\-####," Ext".\ ####;;_

This is the result I got using:
!(999) 000-0000 = (850) 298-4431 (w/ext) & 3109438171, 112 (w/o ext)
!(999) 000-0000, Ext. 0000 = 3109438171, 112 (w/ext) & (   )  85-0298, Ext. 4431 (w/o ext)
ASKER CERTIFIED SOLUTION
Avatar of Jeffrey Coachman
Jeffrey Coachman
Flag of United States of America image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of Laura Sheldon
Laura Sheldon
Flag of United States of America image

ASKER

The calculated field was the answer! Thanks!
Great.

Enjoy the weekend

;-)

Jeff
Microsoft Access
Microsoft Access

Microsoft Access is a rapid application development (RAD) relational database tool. Access can be used for both desktop and web-based applications, and uses VBA (Visual Basic for Applications) as its coding language.

226K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo