Results 1 to 3 of 3
  1. #1
    Gold Lounger
    Join Date
    Feb 2004
    Location
    Cape Town, RSA
    Posts
    3,444
    Thanks
    0
    Thanked 1 Time in 1 Post

    HyperLinks (Access2000)

    Hi there,
    I have a form containing a bound hyperlink text box. I attached a VBA script to the On Got Focus event of the text box to open the Insert Hyperlink dialog box.
    My query is that I need to know how to have the Create New Page option of the dialog display by default. Each time the user clicks the text box and the Hyperlink dialog displays, it must display the Create New Page screen automatically.
    Is there any parameter or any line of code that makes this possible. The line of code I am using currenly is "DoCmd.RunCommand acCmdInsertHyperlink", which only opens the dialog usually on the Existing File or Web Page screen!
    Much abliged to anyone who can help!!
    Thanx
    Rudi
    Regards,
    Rudi

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: HyperLinks (Access2000)

    Hello Rudi,

    Welcome to Woody's Lounge. I think the only way to do this is to use SendKeys to simulate typing Alt+N in the hyperlink dialog. The code for this is

    SendKeys "%N"
    RunCommand acCmdInsertHyperlink

    Note: Alt+N is the shortcut key in Office 2002, I don't know if it was the same in Office 2000. Look for the underlined letter in the dialog.

  3. #3
    Gold Lounger
    Join Date
    Feb 2004
    Location
    Cape Town, RSA
    Posts
    3,444
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: HyperLinks (Access2000)

    HansV, thanks for your hearty welcome. I tried the SendKeys line and it works beautifully. Many thanks to you and Woody's Lounge.
    RudiS
    Regards,
    Rudi

Posting Permissions

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