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
d.tejdeep@nicomatic.ind.tejdeep@nicomatic.in 

want to auto click the link when a field update happens picklist value is “sent"

want to auto click the link when a field update happens picklist value is "sent to customer".

I have a link from website that when i click on link it will change status on website.

what i want is ,Want to auto click that link when a slaesforce field upadte happenes pick list value is"sent to customer".

auto click should run on back ground it should not reload page.

Help me suggesting some ideas .say me this is possible or not
Sagar PareekSagar Pareek
Hi Tejdeep,

On which type of object you are trying to implement this functionality?

One way of doing this is to develop a visualforce page that will look same as that of standard detail page of the object/record. 

If the picklist value of that record is set to sent to customer this page will not be shown instead it will redirect to the website you want to redirect to . 

 
d.tejdeep@nicomatic.ind.tejdeep@nicomatic.in

{!REQUIRESCRIPT("/soap/ajax/19.0/connection.js")} 

var c = new sforce.SObject("service_request__c"); 
c.id = "{!Service_Request__c.Id}"; 
c.status__c = "sent to customer";
var today = new Date(); 
var dd = today.getDate(); 
var mm = today.getMonth()+1; //January is 0! 
var yyyy = today.getFullYear(); 
if(dd<10) { 
dd='0'+dd 

if(mm<10) { 
mm='0'+mm 

today =yyyy+'-'+mm+'-'+ dd;  
c.sentdate__c=today;
var a="{!Service_Request__c.Nicomatic_request_Id__c}".replace(",","");

result = sforce.connection.update([c]);
location.reload(true);


window.open('http://www.nicomatic.com/_1new_website/index.phpaction=ProcessReq3&idd='+'a')


I dont want to use open this url i want to click on this url ( i mean to execute this url ) without opening on new window browser