Learn how to a build a cloud-first strategyRegister Now

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 115
  • Last Modified:

Correct Syntax

Selection.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True, password:="OPPS"

Any help would be greatly appreciated.

  • 2
1 Solution
Wayne Taylor (webtubbs)Commented:
What exactly are you hoping to acheive? Are you wishing to link directly to a password protected page? If so, can you post the link to the site you are trying to access?


ca1358Author Commented:
Thank all of you for this, I had 3 different problems with 3 different connections strings, and all you contributed to me finding the solution.  This particular one I ended using.

Sub OpenAccess()

    Dim LPath As String
    Dim LCategoryID As Long
    Const DBPWD = "OOPS"

    'Path to Access database
    LPath = "\\Dtcnas-ilsp002\mandatory\Analysts - Working Files\Carol\Demo\volume.mdb"

    'Open Access and make visible
    Set oApp = CreateObject("Access.Application")
    oApp.Visible = True

    'Open Access database as defined by LPath variable and , false, dbpwd for password
    oApp.OpenCurrentDatabase LPath, False, DBPWD

    oApp.Application.DoCmd.RunMacro "Macro2CloseSwitchboard"
    oApp.Application.DoCmd.OpenForm "Form"
End Sub
Wayne Taylor (webtubbs)Commented:

Thanks for the points, although I think you may have closed the wrong question. If it is, I can ask Community Support to re-open this question for you.



Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now