Results 1 to 3 of 3
  1. #1
    2 Star Lounger
    Join Date
    Feb 2003
    Location
    Warwick, Warwickshire, England
    Posts
    189
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Does anyone have a routine I could modify allowing me to map a network drive, run an Access application and then unmap the drive when I have finished.

    I have a database which I want to run on a PC, but I don't want to leave other people with the option of using the data from the mapped drive when I have finished. I know they could remap it afterwards, but I'm not going to worry too much about that - though I guess if part of the mapping process could include a username/password that would help with the security.

    Thanks in advance

    John

  2. #2
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts
    Why is there a need to create a mapped drive? Is it a frontend/backend issue? If so, link using the UNC (ex. \\server\data\my.mdb).
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

  3. #3
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts
    [quote name='jaf90' post='773942' date='07-May-2009 02:46']Does anyone have a routine I could modify allowing me to map a network drive, run an Access application and then unmap the drive when I have finished.

    I have a database which I want to run on a PC, but I don't want to leave other people with the option of using the data from the mapped drive when I have finished. I know they could remap it afterwards, but I'm not going to worry too much about that - though I guess if part of the mapping process could include a username/password that would help with the security.

    Thanks in advance

    John[/quote]

    The old DOS command SUBST can be used to map and unmap drives.
    To unmap it again you run it again with the /d switch.


    You can run a DOS command from with Access using the Shell Command.
    So this works for me:

    shell("subst h: D:\john")


    followed later by

    shell("subst h: /d")
    Regards
    John



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •