+ Start a Discussion
chaitu.gadamchaitu.gadam 

how to attach the URL for the custom button

hi,

 

I want the code for which when the user clicks the custom button like "Proceed" ,then the user has to transfer the page to New Lead Registering page.. how to do it in VF page...can u please send the code

Best Answer chosen by Admin (Salesforce Developers) 
asish1989asish1989

 

<apex:commandButton value="Edit" title="to edit contact" id="editButton" action="/apex/YourPagename"  style="color:blue">

 

<apex:commandButton vale="Proceed" action ="{!Proceed}">
public PageReference Proceed() {

PageReference listContact=new PageReference('url');// add your url
or
PageReference listContact=new PageReference('apex/yourpage name');


return listContact;
}

All Answers

asish1989asish1989

 

<apex:commandButton value="Edit" title="to edit contact" id="editButton" action="/apex/YourPagename"  style="color:blue">

 

<apex:commandButton vale="Proceed" action ="{!Proceed}">
public PageReference Proceed() {

PageReference listContact=new PageReference('url');// add your url
or
PageReference listContact=new PageReference('apex/yourpage name');


return listContact;
}

This was selected as the best answer
chaitu.gadamchaitu.gadam

Hi ,

 

thanks asish Its working