Have functions available across databases

maw230

somewhat competent
Local time
, 18:32
Joined
Dec 9, 2009
Messages
522
I just need to access my user-defined functions in all new or old .accdb databases.

In Excel you can save them as an add-in or possibly to your personal workbook, but how can I do this in Access?
 
In access 97 to 2003 you can put all of your user defined functions in a database .mdb or compile to .mde if you want to prevent any changes. Then change the file extension to .mda. In your working db you can open a vba window go to references where you can browse and select your .mda file. I think the same works with access 2010, but I'm guessing there might me a different file extension if the vba db is created in 2007/2010 format.
 
In access 97 to 2003 you can put all of your user defined functions in a database .mdb or compile to .mde if you want to prevent any changes. Then change the file extension to .mda. In your working db you can open a vba window go to references where you can browse and select your .mda file. I think the same works with access 2010, but I'm guessing there might me a different file extension if the vba db is created in 2007/2010 format.

I think there would be a different file extension. Unfortunately, google isn't helping me find it.
 

Well I went through I changed it to .accda > went to VBA window > Tools > References. Then I had to browse to find it, however the only available "add-in" extension was .mda. Since it did offer the ability to add an actual .accdb file I chose one of my other databases and added it. Then I was able to access the functions within it.

So, I didn't even need to make it an .accda! Of course there is probably some reason why I should, but for my purposes this works just fine.

Thanks for the help, John.
 
Glad it works for you.

Either that sites got the extensions wrong or Microsoft have missed it off the list. Wonder if it would work if you went to all files and then selected it. Not 100% sure but i don't think functionallity is compromised by changing a .accdb to .accda, it maybe just to help identify which is an addin file and which is a db file.
 

Users who are viewing this thread

Back
Top Bottom