Ok I am trying to make one db run an append query in another db

which...ok..it works fine using:

Dim DB as Database
Set DB = DBEngine.OpenDatabase(DB_NAME)

DB.Execute "qappDeptInfo"


but!.... the query in the other DB uses VBA Functions to manipulate the data...the only way I could get it to work is to copy the function into the 'calling' db??

Is there any way to make the query use its own version of the code so I dont have to copy over every function thats required??

Thanks!