<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-992969565052585638</id><updated>2024-08-30T09:38:55.654-07:00</updated><category term="apex"/><category term="button"/><category term="controller"/><category term="custom button"/><category term="salesforce"/><category term="visualforce"/><title type='text'>Salesforce Development</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://sfdc-development.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/992969565052585638/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://sfdc-development.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Dharmesh Gohil</name><uri>http://www.blogger.com/profile/13434710776736918213</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>3</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-992969565052585638.post-8916591674371315829</id><published>2012-01-26T13:47:00.000-08:00</published><updated>2012-01-26T13:51:44.273-08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="apex"/><category scheme="http://www.blogger.com/atom/ns#" term="button"/><category scheme="http://www.blogger.com/atom/ns#" term="controller"/><category scheme="http://www.blogger.com/atom/ns#" term="custom button"/><category scheme="http://www.blogger.com/atom/ns#" term="salesforce"/><category scheme="http://www.blogger.com/atom/ns#" term="visualforce"/><title type='text'>Visualforce Custom button</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
As Salesforce has&amp;nbsp;deprecated&amp;nbsp;the sControl and hence there is more need to build the custom button using visualforce. We will go through to designing of custom button using Visualforce and apex code.&lt;br /&gt;
&lt;br /&gt;
Here I have given simple example&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Step - 1 : Create Apex class with logic which needs to execute on click on custom button.&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre&gt;public with sharing class CustomButtonExample {
    private final ApexPages.StandardController theController;

    public CustomButtonExample (ApexPages.StandardController controller) {
        theController = controller;
    }

    public PageReference doCheckLogic() {
     String theId = ApexPages.currentPage().getParameters().get(&#39;id&#39;);
        try{
            // do something
        }
        catch(Exception e){
        }
       return theController.view().setRedirect(true);
    }
}
&lt;/pre&gt;
&lt;br /&gt;
&lt;b&gt;Step - 2 : Create Visualforce&lt;/b&gt;
&lt;br /&gt;
&lt;pre&gt;   
   &amp;lt;apex:page action=&quot;{!doCheckLogic}&quot; extensions=&quot;CustomButtonExample&quot; 
            standardcontroller=&quot;Opportunity&quot;&amp;gt; &amp;lt;/apex:page&amp;gt;
&lt;/pre&gt;
&lt;pre&gt;&lt;/pre&gt;
&lt;pre&gt;Remember that the custom controller you build must be extensions 
in Visualforce page.&lt;/pre&gt;
&lt;br /&gt;
&lt;b&gt;Step - 3 : Create Custom Button&lt;/b&gt;&lt;br /&gt;
Go to setup-&amp;gt;App Setup-&amp;gt; Customize -&amp;gt; Custom Object -&amp;gt; Buttons and Links
provide the parameters and select the Visualforce create from the list.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Step - 4 : Put Custom button on page layout.&lt;/b&gt;
&lt;br /&gt;
&lt;br /&gt;
You are done !!&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sfdc-development.blogspot.com/feeds/8916591674371315829/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sfdc-development.blogspot.com/2012/01/visualforce-custom-button.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/992969565052585638/posts/default/8916591674371315829'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/992969565052585638/posts/default/8916591674371315829'/><link rel='alternate' type='text/html' href='http://sfdc-development.blogspot.com/2012/01/visualforce-custom-button.html' title='Visualforce Custom button'/><author><name>Dharmesh Gohil</name><uri>http://www.blogger.com/profile/13434710776736918213</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-992969565052585638.post-5485229937241946204</id><published>2010-12-15T23:42:00.000-08:00</published><updated>2010-12-15T23:54:49.808-08:00</updated><title type='text'>Salesforce Interview Questions</title><content type='html'>1)  How do you hide Header and Sidebar on Visualforce page?&lt;div&gt;2) What is difference between standard and custom controller?&lt;/div&gt;&lt;div&gt;3) What is Controller extension?&lt;/div&gt;&lt;div&gt;4) How do you read parameter in Visualforce page?&lt;/div&gt;&lt;div&gt;5) How many dependent drop down can be put on one Visualforce page?&lt;/div&gt;&lt;div&gt;6) What is the maximum size of the PDF generated on Visualforce attribute renderAs?&lt;/div&gt;&lt;div&gt;7) How to use actionPoller tag?&lt;/div&gt;&lt;div&gt;8) What is difference between actionFunction and actionSupport Tag ?&lt;/div&gt;&lt;div&gt;9) How can we check the object accessibility on visualforce page?&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt; &lt;/span&gt;-{!$ObjectType.MyCustomObject__c.accessible}&lt;/div&gt;&lt;div&gt;10)  How many rows return by list controller?&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space:pre&quot;&gt; &lt;/span&gt;-10000&lt;/div&gt;&lt;div&gt;11) What is custom component?&lt;/div&gt;&lt;div&gt;12) What is assignTo attribute and what is its use?&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sfdc-development.blogspot.com/feeds/5485229937241946204/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sfdc-development.blogspot.com/2010/12/salesforce-interview-questions.html#comment-form' title='9 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/992969565052585638/posts/default/5485229937241946204'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/992969565052585638/posts/default/5485229937241946204'/><link rel='alternate' type='text/html' href='http://sfdc-development.blogspot.com/2010/12/salesforce-interview-questions.html' title='Salesforce Interview Questions'/><author><name>Dharmesh Gohil</name><uri>http://www.blogger.com/profile/13434710776736918213</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>9</thr:total></entry><entry><id>tag:blogger.com,1999:blog-992969565052585638.post-6115841760980468180</id><published>2010-12-15T23:38:00.000-08:00</published><updated>2010-12-15T23:40:10.004-08:00</updated><title type='text'>Welcome to Salesforce Development Blog</title><content type='html'>Welcome to Salesforce Development. We will discuss various aspect of the Salesforce. Problem and solution of the Salesforce and some development tips for the Developer.</content><link rel='replies' type='application/atom+xml' href='http://sfdc-development.blogspot.com/feeds/6115841760980468180/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sfdc-development.blogspot.com/2010/12/welcome-to-salesforce-development-blog.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/992969565052585638/posts/default/6115841760980468180'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/992969565052585638/posts/default/6115841760980468180'/><link rel='alternate' type='text/html' href='http://sfdc-development.blogspot.com/2010/12/welcome-to-salesforce-development-blog.html' title='Welcome to Salesforce Development Blog'/><author><name>Dharmesh Gohil</name><uri>http://www.blogger.com/profile/13434710776736918213</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry></feed>