If you are talking UDF in SQL Server and trying to use it in your Access ADP
frontend's VBA code, the answer is no: UDF runs inside SQL Server, the
backend, while your Access ADP VBA code runs in, well, Access ADP, the
frontend. UDF is meant to be used for qerying the SQL Server, such as in
SPs.
You could "indirectly" use the UDF in you Access ADP's VBA code to get a
value being returned from SQL Server, though. Such as:
Dim str as String
str=GetMyValueFromDB()
Private Function GetMyValueFromDB() As String
'' Declare a ADO Command object
'' Add input/output parameters as you need
'' Execute the Command, which call a SP in SQL Server, which in turn
calls your UDF.
''The value return by the UDF get passed back to your VBA code in the
form of output parameter
GetMyValueFromDB=cmd.Paramater("OutputParam").Value
End