Dec 21, 2005 #1 hstijnen Programmer Joined Nov 13, 2002 Messages 172 Location NL Hi, How can I find in VBA for Access the name of the .mdb file I'm working in? Thanks Henk
Dec 21, 2005 #2 AlexMidd Programmer Joined May 14, 2001 Messages 655 Location NL currentdb.name Have fun! ) Alex Middleton Upvote 0 Downvote
Dec 21, 2005 1 #3 RoyVidar Instructor Joined Jun 16, 2000 Messages 6,606 Location NO Or use currentproject.name (no need to strip of the path) Roy-Vidar Upvote 0 Downvote
Dec 22, 2005 #4 MajP Technical User Joined Aug 27, 2005 Messages 9,382 Location US This may also be helpful in other cases to find the back end name: dim strPathAndFile strPathAndFile = CurrentDb.TableDefs(mLinkedTableName).Connect strPathAndFile = Mid(strPathAndFile, 11) where mLinkedTableName is the name of a linked table Upvote 0 Downvote
This may also be helpful in other cases to find the back end name: dim strPathAndFile strPathAndFile = CurrentDb.TableDefs(mLinkedTableName).Connect strPathAndFile = Mid(strPathAndFile, 11) where mLinkedTableName is the name of a linked table