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
karol.freebergkarol.freeberg 

JavaScript button with 2 URLs not workings.

I have a detail button on a lead with the following code. It is set to Execute Javascript.

javascript:window.open("http://www.versodigitalpapers.com" );void(0); 
javascript:window.open("/flow/Verso_Digital_Paper_Request_for_Leads?GetLeadID={!Lead.Id}" );void(0);

The problem is it executes the first line fine but does not do the second line. Is there a way to do this within one button. If I switch the lines around, it will do the flow but not go to the external site. The flow creates a task. Any ideas?
Best Answer chosen by karol.freeberg
Neetu_BansalNeetu_Bansal
Hi Karol,

It is not possible to open two URL's from a single button like you did, for this either create a visualforce page, which on complete of first url, open the second one. I can do that for you, you can contact me on either my gmail id: neetu.bansal.5@gmail.com or Skype id: neetu.bansal.5

Let me know if you need any other help.

Thanks,
Neetu