function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
ShaTShaT 

Open hyperlink on button click

Hi,

I am trying to open a hyperlink on my account record. I have field website on Account. I have created a button which will open the website.
i treid with URL but its adds the salesforce url and than addes the website

Could any one provide me the sloution.

Thanks
ShaT
Best Answer chosen by ShaT
Jai ChaturvediJai Chaturvedi
Try this one.

window.open('http://{!Account.Website }','_blank')

Website is your field name.

If this solves your problem, kindly mark it as the solution.

All Answers

Vatsal KothariVatsal Kothari
Hi,

You can do this by creating new custom button of that object where select "Display Type" as "Detail Page Button" and "Content Source" as "Onclick Javascript" and add below line in formula field:
window.open('https://www.google.com','_blank')
add this button to your page layout.

If this solves your problem, kindly mark it as the best answer.

Thanks,
Vatsal
Jai ChaturvediJai Chaturvedi
Try this one.

window.open('http://{!Account.Website }','_blank')

Website is your field name.

If this solves your problem, kindly mark it as the solution.
This was selected as the best answer