Path of back-end

  • Thread starter Thread starter George
  • Start date Start date
G

George

Hi all,

In Acess XP, one can use Application.CurrentProject.Path
to determine the path of the front-end. Is there a similar
way to determine the path of the back-end?

TIA.
 
I use a query that returns the name of the backend using a linked table
name:

SELECT MSysObjects.Database
FROM MSysObjects
WHERE (((MSysObjects.ForeignName) Like "NameOfALinkedTable"));
 
George said:
In Acess XP, one can use Application.CurrentProject.Path
to determine the path of the front-end. Is there a similar
way to determine the path of the back-end?

Which back end? Every linked table in the front end could
be in a different back end.

You can extract the path to a linked table's mdb file from
the linked table's Connect property:

Dim dbFE As Database
Dim tdf As TableDef
Dim strBEpath As String

Set dbFE = CurrentDb()
Set tdf = dbFE.TableDefs("nameoflinkedtable")
strBEpath = Mid(tdf.Connect, 11)
 
Back
Top