open self database

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • stephane
    New Member
    • Feb 2007
    • 35

    open self database

    hi
    using selects queryes with DAO works well.
    i've got a code
    Set MyDB = OpenDatabase("C :\folder\voyage s.mdb")

    but i want make datebase with independent path, so user can put it into other folders and it must works.
    is any methods to open self base, don't using self path?
    or is any methods to determine self path?
  • NeoPa
    Recognized Expert Moderator MVP
    • Oct 2006
    • 32636

    #2
    Look in CurrentDB.Name.
    You will have to extract it from the full name by finding the last "\" char.

    Comment

    • stephane
      New Member
      • Feb 2007
      • 35

      #3
      i find solution

      Set MyDB = CurrentDb()

      it works)

      Comment

      • NeoPa
        Recognized Expert Moderator MVP
        • Oct 2006
        • 32636

        #4
        I didn't understand that that was what you needed - sorry.
        You got your answer anyway, so that's good.

        Comment

        Working...