+ Reply to Thread
Results 1 to 16 of 16

Create shortcut to open a link to a website?

  1. #1
    Registered User
    Join Date
    02-10-2020
    Location
    Denmark
    MS-Off Ver
    2016 Mac
    Posts
    9

    Create shortcut to open a link to a website?

    Hi,

    I have an Excel document where I open a lot of link to websites. Right now I have to click on each link in each cell to open the websites they're directing to. But it would be much easier, if I just had a shortcut for this rather than have to click on the cell.

    Unfortunately, I have not really been able to figure out how to do this. I'm using Excel 2016 for Mac.

    Thanks!

  2. #2
    Valued Forum Contributor PaulSP8's Avatar
    Join Date
    11-21-2017
    Location
    Chorley, England
    MS-Off Ver
    2013 & 2021
    Posts
    437

    Re: Create shortcut to open a link to a website?

    Not sure if I've understood correctly, but I imagine you to have links to websites set up in different cells?

    You can use a Macro to follow them all in one go, like;

    Please Login or Register  to view this content.
    Amend the Ranges to suit.

    Or, if you've get them all lined up in a column you could do it like this;

    Please Login or Register  to view this content.
    If that's not what you wanted then post back with more details.

  3. #3
    Registered User
    Join Date
    02-10-2020
    Location
    Denmark
    MS-Off Ver
    2016 Mac
    Posts
    9

    Re: Create shortcut to open a link to a website?

    That's correct.

    But it is only the link(s) of the cell(s) I'm currently on or marking I would like to open. Typically, it just the link of the cell I'm currently on, I would like to open.

  4. #4
    Valued Forum Contributor PaulSP8's Avatar
    Join Date
    11-21-2017
    Location
    Chorley, England
    MS-Off Ver
    2013 & 2021
    Posts
    437

    Re: Create shortcut to open a link to a website?

    I'm sorry I don't understand what advantage a "shortcut" would have over a hyperlink in that case?

    Am I missing something?

    Perhaps if you could upload a sample workbook (instructions on the Yellow Banner above) it would help to see what you're trying to achieve?

  5. #5
    Registered User
    Join Date
    02-10-2020
    Location
    Denmark
    MS-Off Ver
    2016 Mac
    Posts
    9

    Re: Create shortcut to open a link to a website?

    Instead of having to click on the cell with the mouse to open the link, I can just navigate to the cell using the keyboard, and then with a keyboard shortcut, I can open the link.

  6. #6
    Valued Forum Contributor PaulSP8's Avatar
    Join Date
    11-21-2017
    Location
    Chorley, England
    MS-Off Ver
    2013 & 2021
    Posts
    437

    Re: Create shortcut to open a link to a website?

    Ah! - OK - So, use this code...

    Please Login or Register  to view this content.
    Then use the Developer > Macros menu and select the Macro from the list, on the right hand side you'll see "Options" - Click on that and it'll allow you to assign a keyboard shortcut to that Macro, pick your key that you'd like to use and you should be good to go

    If you need more help then see > https://support.office.com/en-gb/art...2-1b5e8e81d96a <

  7. #7
    Registered User
    Join Date
    02-10-2020
    Location
    Denmark
    MS-Off Ver
    2016 Mac
    Posts
    9

    Re: Create shortcut to open a link to a website?

    Thanks a lot. Didn't work, but I think that's because I have not stated the scenario properly.

    Each cell has a name, and that name then has a link, if that make sense? So I can have a cell named "cell1". "cell1" has a link to excelforum.com eg.

  8. #8
    Valued Forum Contributor PaulSP8's Avatar
    Join Date
    11-21-2017
    Location
    Chorley, England
    MS-Off Ver
    2013 & 2021
    Posts
    437

    Re: Create shortcut to open a link to a website?

    Can you upload an example in an Excel file attachment so we can see exactly what you are dealing with please?

    Thanks.

  9. #9
    Registered User
    Join Date
    02-10-2020
    Location
    Denmark
    MS-Off Ver
    2016 Mac
    Posts
    9

    Re: Create shortcut to open a link to a website?

    I've attached an example.

    Each cell has some text, but also a link attached. I want to open the link.
    Attached Files Attached Files

  10. #10
    Valued Forum Contributor PaulSP8's Avatar
    Join Date
    11-21-2017
    Location
    Chorley, England
    MS-Off Ver
    2013 & 2021
    Posts
    437

    Re: Create shortcut to open a link to a website?

    Right. This is a weird one.

    I took a look at your Workbook and couldn't get anything to work, I kept getting Errors when trying to open the Hyperlink and I couldn't work out why.

    Then I tried to actually click on your link, and I got the exact same error message when trying to open the link as when I was trying to do it in VBA.

    So, I added some of mine and they all worked perfectly when I clicked on them and when I used VBA.

    In short - I'm stumped.

    Research suggests that the URL can't be longer than 255 characters (which none are), it also suggests there are registry fixes for the problem on a Windows machine (which won't help you). It could also be something to do with this site blocking certain things from happening as I couldn get the same links to work in a new Workbook when I tried to recreate what you'd done after seeing it work on my selected links.

    So, much as I hate to admit defeat I'm clueless at this point

    I've attached what I've done so you can see if you can it to work for you - I've added a Google link and a few Amazon links and they all work if you go to the cell and press CTRL & M (You'll need to change this to whatever works on a Mac (Option & Cmd at a guess).

    The code is simply;

    Please Login or Register  to view this content.
    Hopefully it'll work with your real world need
    Attached Files Attached Files

  11. #11
    Registered User
    Join Date
    02-10-2020
    Location
    Denmark
    MS-Off Ver
    2016 Mac
    Posts
    9

    Re: Create shortcut to open a link to a website?

    It worked exactly as it should!

    Thank you very, very much for taking the time to help me. Have a nice day!

  12. #12
    Registered User
    Join Date
    02-10-2020
    Location
    Denmark
    MS-Off Ver
    2016 Mac
    Posts
    9

    Re: Create shortcut to open a link to a website?

    Another question actually:

    Normally, when you click a link, it changes color from blue to purple. When using shortcut, it does not change color.

    Is it possible to do this behaviour still even though we use the shortcut?

  13. #13
    Valued Forum Contributor PaulSP8's Avatar
    Join Date
    11-21-2017
    Location
    Chorley, England
    MS-Off Ver
    2013 & 2021
    Posts
    437

    Re: Create shortcut to open a link to a website?

    Really glad to hear it's working, was properly confusing me at first :-/

    Yeah, you can change the colour - But it'll be a permanent change;

    Please Login or Register  to view this content.

  14. #14
    Registered User
    Join Date
    02-10-2020
    Location
    Denmark
    MS-Off Ver
    2016 Mac
    Posts
    9

    Re: Create shortcut to open a link to a website?

    Just me that's bad at explaining it.

    Thanks again, but there isn't anyway to get the exact same behaviour, so it doesn't stay permanent?

  15. #15
    Valued Forum Contributor PaulSP8's Avatar
    Join Date
    11-21-2017
    Location
    Chorley, England
    MS-Off Ver
    2013 & 2021
    Posts
    437

    Re: Create shortcut to open a link to a website?

    No - I knew what you meant - I hadn't realised that they weren't changing colour actually.

    Unfortunately I can't seem to see a way to make them do it either, sorry.

  16. #16
    Registered User
    Join Date
    02-10-2020
    Location
    Denmark
    MS-Off Ver
    2016 Mac
    Posts
    9

    Re: Create shortcut to open a link to a website?

    No problem, and once again, thank you very much!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. How do I create a hotkey to open a link when I'm clicked on the cell?
    By kmgilroy89 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-27-2016, 11:45 PM
  2. Write macro to open link and copy/paste content from website
    By snuffnchess in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-20-2016, 11:10 AM
  3. How to open a website and click on a link and open the file to capy
    By CityMPLSEmpolyee in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-13-2016, 02:12 PM
  4. [SOLVED] can i create a shortcut to open a spreadsheet read only?
    By Mark in forum Excel General
    Replies: 2
    Last Post: 07-13-2015, 02:32 PM
  5. Create Excel Template shortcut on first open
    By thecdnmole in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 09-27-2014, 12:02 PM
  6. Create the user form shortcut without open Excel workbook. Does it possible?
    By pyol17 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-10-2012, 11:47 PM
  7. Replies: 2
    Last Post: 08-17-2009, 08:27 AM

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1