Open/close Navigation Pane programatically

Discussion in 'Access VBA Modules' started by accesswanabe, Mar 10, 2010.

  1. accesswanabe

    accesswanabe Guest

    I'm using the following VBA code to establish a link from a field Access
    database to a main office Access database: DoCmd.TransferDatabase acLink,
    "Microsoft Access", "G:\ThePath\Transaction Database.accdb", acTable,
    "tblInputNDETrans", "tblInputNDETrans"

    As soon as the line starts to execute, the Navigation Pane pops open (even
    though I have it turned off in "Access Options") exposing the field database
    objects to who knows what. I really don't ever want this to happen for
    obvious security reasons.

    Is there a way to control the Navigation Panel with VBA or does someone have
    a suggestion about doing something like this in another way?

    Thanks!!
     
    accesswanabe, Mar 10, 2010
    #1
    1. Advertisements

  2. accesswanabe

    accesswanabe Guest

    Found this solution although it is more of a work around rather than a good
    solution.

    DoCmd.SelectObject acTable, "NavigationPaneObject", True
    DoCmd.RunCommand acCmdWindowHide

    NavigationPaneObject = any object that is configured to be selectable within
    the pane.



    "accesswanabe" wrote:

    > I'm using the following VBA code to establish a link from a field Access
    > database to a main office Access database: DoCmd.TransferDatabase acLink,
    > "Microsoft Access", "G:\ThePath\Transaction Database.accdb", acTable,
    > "tblInputNDETrans", "tblInputNDETrans"
    >
    > As soon as the line starts to execute, the Navigation Pane pops open (even
    > though I have it turned off in "Access Options") exposing the field database
    > objects to who knows what. I really don't ever want this to happen for
    > obvious security reasons.
    >
    > Is there a way to control the Navigation Panel with VBA or does someone have
    > a suggestion about doing something like this in another way?
    >
    > Thanks!!
     
    accesswanabe, Mar 12, 2010
    #2
    1. Advertisements

  3. hide Navigation Pane with code

    I already tried the solution you described.
    Is there any way to prevent opening of Navigation Pane during execution of code ? (the same appens to me when linking to external tables)
    Or ... is there any way to hide Navigation Pane with code (besides the selectable objects within the pane)
    Thanks



    accesswanabe wrote:

    Found this solution although it is more of a work around rather than a
    12-Mar-10

    Found this solution although it is more of a work around rather than a goo
    solution

    DoCmd.SelectObject acTable, "NavigationPaneObject", Tru
    DoCmd.RunCommand acCmdWindowHid

    NavigationPaneObject = any object that is configured to be selectable withi
    the pane


    "accesswanabe" wrote:

    Previous Posts In This Thread:

    On Wednesday, March 10, 2010 6:20 PM
    accesswanabe wrote:

    Open/close Navigation Pane programatically
    I am using the following VBA code to establish a link from a field Acces
    database to a main office Access database: DoCmd.TransferDatabase acLink
    "Microsoft Access", "G:\ThePath\Transaction Database.accdb", acTable
    "tblInputNDETrans", "tblInputNDETrans

    As soon as the line starts to execute, the Navigation Pane pops open (eve
    though I have it turned off in "Access Options") exposing the field databas
    objects to who knows what. I really do not ever want this to happen fo
    obvious security reasons

    Is there a way to control the Navigation Panel with VBA or does someone hav
    a suggestion about doing something like this in another way

    Thanks!!

    On Friday, March 12, 2010 9:04 AM
    accesswanabe wrote:

    Found this solution although it is more of a work around rather than a
    Found this solution although it is more of a work around rather than a goo
    solution

    DoCmd.SelectObject acTable, "NavigationPaneObject", Tru
    DoCmd.RunCommand acCmdWindowHid

    NavigationPaneObject = any object that is configured to be selectable withi
    the pane


    "accesswanabe" wrote:


    Submitted via EggHeadCafe - Software Developer Portal of Choice
    Distributed Data Grids - Share Objects Between Windows Service and ASP.NET
    http://www.eggheadcafe.com/tutorial...b7a-1bb00e33db07/distributed-data-grids-.aspx
     
    Jose Catarino, May 10, 2010
    #3
  4. accesswanabe

    Sky Guest

    Re: hide Navigation Pane with code

    On 5/10/2010 6:36 AM, Jose Catarino wrote:
    > I already tried the solution you described.
    > Is there any way to prevent opening of Navigation Pane during execution of code ? (the same appens to me when linking to external tables)
    > Or ... is there any way to hide Navigation Pane with code (besides the selectable objects within the pane)
    > Thanks
    >


    The following hide method does not require pre-configuring the
    Navigation Pane to show the proper selectable objects:

    DoCmd.NavigateTo "acNavigationCategoryObjectType"
    DoCmd.RunCommand acCmdWindowHide

    Steve
     
    Sky, May 10, 2010
    #4
  5. accesswanabe

    Guest

    This code is unreliable!!!
    DoCmd.SelectObject acTable, "NavigationPaneObject", True
    DoCmd.RunCommand acCmdWindowHide
    will FAIL if all of the sections of the nav "PAIN" are minimized and it will hide whatever form has the focus.

    Still looking for a rock solid solution.
     
    , Aug 1, 2012
    #5
    1. Advertisements

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Similar Threads
  1. Valery2105
    Replies:
    1
    Views:
    207
    John Spencer
    May 25, 2006
  2. lhanssen
    Replies:
    0
    Views:
    141
    lhanssen
    Sep 25, 2006
  3. EWaters

    Suppress Navigation Pane Through Code

    EWaters, Mar 15, 2007, in forum: Access VBA Modules
    Replies:
    2
    Views:
    106
    EWaters
    Mar 16, 2007
  4. dtoland

    Access Navigation Pane VBA access

    dtoland, Aug 21, 2007, in forum: Access VBA Modules
    Replies:
    1
    Views:
    142
    Jeff Conrad [MSFT]
    Aug 21, 2007
  5. Mike Sorel

    Navigation Pane

    Mike Sorel, Feb 28, 2008, in forum: Access VBA Modules
    Replies:
    1
    Views:
    118
    Tom van Stiphout
    Feb 28, 2008
  6. wmdmurphy

    Hiding navigation pane in Access 2007

    wmdmurphy, Apr 16, 2008, in forum: Access VBA Modules
    Replies:
    1
    Views:
    123
    Damon Heron
    Apr 16, 2008
  7. ND Pard
    Replies:
    0
    Views:
    219
    ND Pard
    Aug 19, 2008
  8. Ken Warthen

    Testing for Open Navigation Pane

    Ken Warthen, Nov 3, 2008, in forum: Access VBA Modules
    Replies:
    6
    Views:
    328
    Ken Warthen
    Nov 4, 2008
Loading...