+ Reply to Thread
Results 1 to 5 of 5

Macro or VBA that opens browser and pastes a link similar to hyperlink

  1. #1
    Registered User
    Join Date
    03-26-2021
    Location
    Fort Worth, TX
    MS-Off Ver
    365
    Posts
    18

    Macro or VBA that opens browser and pastes a link similar to hyperlink

    So I'm creating a spread sheet that is trying to essentially use hyperlinks to automatically take you to a specific webpage. However, the data base I'm using actively tries to block links from external sources but will accept links if pasted in the browser.

    Basically I'd like to create a hyperlink that runs a macro or VBA program that runs in this order:

    Open Edge -> New Tab -> Paste URL link -> search

    It's really just a hyper link but going in a roundabout way. If there's a program I can run and just change out the URL for each individual link that would be great!
    Last edited by mstark17; 03-31-2021 at 06:00 PM.

  2. #2
    Registered User
    Join Date
    03-28-2021
    Location
    London
    MS-Off Ver
    365
    Posts
    11

    Re: Macro or VBA that opens browser and pastes a link similar to hyperlink

    Since we don't know how the database blocks non pasted links, it's hard to know what will work.

    One thing that might work is feeding the URL in via a command prompt - try opening up the cmd prompt and pasting in the following (changing *url* to a database URL) "C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe" *url*

    If that avoids the block, then you can do the same in a VBA macro with a sub which you can call with any URL such as the following

    Please Login or Register  to view this content.
    call this using e.g.
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    03-26-2021
    Location
    Fort Worth, TX
    MS-Off Ver
    365
    Posts
    18

    Re: Macro or VBA that opens browser and pastes a link similar to hyperlink

    ok, running that command though cmd worked. I put your code in excel and was able to get it working as well.

    The final thing would be how can I run the code as a hyperlink? Can't find a good reference but I'd like to run the code similar to clicking on a hyperlink

  4. #4
    Registered User
    Join Date
    03-26-2021
    Location
    Fort Worth, TX
    MS-Off Ver
    365
    Posts
    18

    Re: Macro or VBA that opens browser and pastes a link similar to hyperlink

    I managed to figure it out. Thanks

  5. #5
    Registered User
    Join Date
    03-26-2021
    Location
    Fort Worth, TX
    MS-Off Ver
    365
    Posts
    18

    Re: Macro or VBA that opens browser and pastes a link similar to hyperlink

    Quote Originally Posted by simoncm View Post
    Since we don't know how the database blocks non pasted links, it's hard to know what will work.

    One thing that might work is feeding the URL in via a command prompt - try opening up the cmd prompt and pasting in the following (changing *url* to a database URL) "C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe" *url*

    If that avoids the block, then you can do the same in a VBA macro with a sub which you can call with any URL such as the following

    Please Login or Register  to view this content.
    call this using e.g.
    Please Login or Register  to view this content.
    Special request, I don't know if this is possible but I've been asked to put this on our server so it's accessible to multiple users. This wouldn't be a problem if they didn't ask if it could be used for chrome instead of edge. As everyone most likely has a different install addresses for chrome is there a way where I can set it to have a variable default user lookup command so it's not tied to just one person?

    For example, could I do this?
    Please Login or Register  to view this content.
    This is also hopefully assuming that everyone has the same install path as well. But with path location being admin locked I think it's ok to set it to this default location.

+ 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. Replies: 3
    Last Post: 09-20-2017, 03:59 PM
  2. Macro which opens Browse window and pastes the file name to a cell ?
    By keimoon in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-27-2012, 07:54 AM
  3. Excel macro that opens new MS Word file and pastes data as a pictu
    By Rob in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 12:05 PM
  4. [SOLVED] Excel macro that opens new MS Word file and pastes data as a pictu
    By Rob in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 04:05 AM
  5. Excel macro that opens new MS Word file and pastes data as a pictu
    By Rob in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 02:05 AM
  6. Excel macro that opens new MS Word file and pastes data as a pictu
    By Rob in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 01:05 AM
  7. Excel macro that opens new MS Word file and pastes data as a pictu
    By Rob in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-05-2005, 11:05 PM

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