Query to contain function to set input mask at run time

  • Thread starter Thread starter Dale
  • Start date Start date
D

Dale

Is there any way to reference a field in a query to set the input mask?
Something like

Function FPager(pager As Field)
Dim F As Field
If Len(pager) > 8 Then
F.InputMask = "###\-####" & " Ext " & "####"
Else
F.InputMask = "###\-####"
End If

This of course doesn't work or I wouldn't be here :)

Thanks as always...
 
In VBA code, via DAO you can modify the property of the table def. So, in
conjuction with the query, you can perform the task.
 
Back
Top