VBA to link cell to website regardless of cell content.

MJ72

Board Regular
Joined
Aug 17, 2021
Messages
64
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
Hello all!
I am setting up a data base for my coworkers and one column is a client phone number column.
I would like to create a vba that will link the cells in that column to a specific website that won't change even when my coworkers enter and/or change the phone numbers in the cells of that column.

I have been successful, just linking the column cells to the website (that part is an easy right click, as you know) but as soon as the phone number is deleted, changed or a new one is added, it overrides the link and clicking the cell then goes nowhere. How do I "lock" that website to the cells in that column so that regardless of the cell content, clicking on the cell always goes to the website?

Thanks

MJ
 
I must be tired, I'm an idiot... ms Forms 2.0 checked... but still having the issue of it autopopulating the phone number into every cell in the column. It does, however, open the proper website upon being clicked and does copy the phone number allowing it to be pasted in the search bar of the website as desired.

I've tried playing around with the order of your first and second sets of code and I just can't seem to stop it from autopopulating AND have it continue to work properly.
 
Upvote 0

Excel Facts

How can you turn a range sideways?
Copy the range. Select a blank cell. Right-click, Paste Special, then choose Transpose.
Okay that makes sense. When you put one formula in a column of a table it copies it to the entire column. Here’s a thread with some tips to prevent the table from doing that.

 
Upvote 0
Solution
That was it! Thank you very much, Joe!
Cheers

MJ
 
Upvote 0
That was it! Thank you very much, Joe!

The marked solution has been changed accordingly. In your future questions, please mark the post as the solution that actually answered your question, instead of your feedback message as it will help future readers. No further action is required for this thread.
 
Upvote 0

Forum statistics

Threads
1,223,234
Messages
6,170,891
Members
452,366
Latest member
TePunaBloke

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top