<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>

<channel>
	<title>Perspectives on Salesforce.com &#187; Configuration</title>
	<atom:link href="http://sfdc.arrowpointe.com/taxonomy/category/Configuration/feed" rel="self" type="application/rss+xml" />
	<link>http://sfdc.arrowpointe.com</link>
	<description>Authored by Scott Hemmeter of Arrowpointe Corp, this blog is written from the perspective of a Salesforce.com solution provider and contains information on Arrowpointe's AppExchange products as well as tips, findings, sample code, functionality wishes, etc.</description>
	<pubDate>Fri, 31 Oct 2008 20:15:16 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.2</generator>
	<language>en</language>
			<item>
		<title>Sidebar Summary using Visualforce</title>
		<link>http://sfdc.arrowpointe.com/2008/09/17/sidebar-summary-using-visualforce/</link>
		<comments>http://sfdc.arrowpointe.com/2008/09/17/sidebar-summary-using-visualforce/#comments</comments>
		<pubDate>Thu, 18 Sep 2008 06:11:41 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[APEX Code]]></category>

		<category><![CDATA[API]]></category>

		<category><![CDATA[Arrowpointe Products]]></category>

		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[Sidebar Summary]]></category>

		<category><![CDATA[Tips]]></category>

		<category><![CDATA[Visualforce]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/?p=395</guid>
		<description><![CDATA[About a year ago, I posted about the Sidebar Summary.  The Sidebar Summary exists in the Salesforce.com sidebar and displays the counts of some important queries.  The counts are also hyperlinks to a view or report representing that query.  It&#8217;s a very handy thing to have in your sidebar and I use it all the [...]]]></description>
			<content:encoded><![CDATA[<p>About a year ago, I posted about the <a href="http://sfdc.arrowpointe.com/2007/08/28/sidebar-summary/" target="_self">Sidebar Summary</a>.  The Sidebar Summary exists in the Salesforce.com sidebar and displays the counts of some important queries.  The counts are also hyperlinks to a view or report representing that query.  It&#8217;s a very handy thing to have in your sidebar and I use it all the time for my own work.  However, because it&#8217;s an s-Control, it runs a little slow.  In fact, it ran slow enough to make me uncheck the user interface option &#8220;Show Custom Sidebar Components on All Pages&#8221;.</p>
<p style="text-align: center;"><img class="size-full wp-image-398 aligncenter" title="sidebarsummary" src="http://sfdc.arrowpointe.com/wp-content/images/sidebarsummary.png" alt="" width="353" height="310" /></p>
<p>I changed it into a Visualforce page with a custom Apex controller and now it runs super fast and I am able to keep the &#8220;Show Custom Sidebar Components on All Pages&#8221; option turned on and see it on every page I go to.  There&#8217;s a bit of hardcoding in here, but it gets the job done pretty well.  Bye bye s-Control.</p>
<p><span style="text-decoration: underline;"><strong>Visualforce</strong></span></p>
<p>The Page is almost all raw HTML.  The only dynamic thing in there are the count values.  Each one retrieves the value from a specific &#8220;get&#8221; method in the controller.  If you like the queries I use, then the only thing you&#8217;ll need to confirm are the URLs that get linked to.  The first 2 go to Views in my Org and the last 2 go to Reports in my Org.  You&#8217;ll need to change those URLs.</p>
<p>I named the VF Page &#8220;<span id="j_id0:theTemplate:j_id7:j_id8:j_id16:j_id17">SidebarSummary&#8221;.</span></p>
<pre class="syntax-highlight:html">

&lt;apex:page controller=&quot;VFController_Sidebar_Summary&quot; sidebar=&quot;false&quot; showHeader=&quot;false&quot; standardStylesheets=&quot;true&quot;&gt;
&lt;style type=&quot;text/css&quot; media=&quot;all&quot;&gt;
body{margin: 0; padding: 0; color: #000000; background-color: #E8E8E8;}
#DIV_Container {background-color: #F3F3EC;}
&lt;/style&gt;
&lt;div id=&quot;DIV_Container&quot;&gt;
&lt;table&gt;
&lt;tr&gt;&lt;td&gt;&lt;em&gt;Unread Leads&lt;/em&gt;:  &lt;/td&gt;&lt;td&gt;&lt;a href=&quot;/00Q?fcf=00B30000005JhsT&quot; target=&quot;_parent&quot;&gt;&lt;b&gt;{!UnreadLeads}&lt;/b&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;&lt;em&gt;Leads - Not Contacted&lt;/em&gt;:  &lt;/td&gt;&lt;td&gt;&lt;a href=&quot;/00Q?fcf=00B30000005Jhru&quot; target=&quot;_parent&quot;&gt;&lt;b&gt;{!NotContactedLeads}&lt;/b&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;&lt;em&gt;Oppty - Next 30 Days&lt;/em&gt;:  &lt;/td&gt;&lt;td&gt;&lt;a href=&quot;/00O30000001aEHV&quot; target=&quot;_parent&quot;&gt;&lt;b&gt;{!Next30DayOppty}&lt;/b&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;&lt;em&gt;Oppty - Past Due&lt;/em&gt;:  &lt;/td&gt;&lt;td&gt;&lt;a href=&quot;/00O30000001aEHV&quot; target=&quot;_parent&quot;&gt;&lt;b&gt;{!PastDueOppty}&lt;/b&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;/apex:page&gt;
</pre>
<p><span style="text-decoration: underline;"><strong>Apex</strong></span></p>
<p>The controller has a method for each query to be run.  Each query is a count() query and returns an Integer.  At the end is a really lame Test method, but it does get 100% of the code covered.  I am certain the code works, so I didn&#8217;t do too much with the Test method.  Salesforce just requires the code to be tested.</p>
<pre class="syntax-highlight:java">

public class VFController_Sidebar_Summary {

public Integer getUnreadLeads() {
return [
select count() from Lead
where IsConverted = False
AND IsUnreadByOwner = TRUE
];
}

public Integer getNotContactedLeads() {
return [
select count() from Lead
where IsConverted = False
AND Status = &#039;Open - Not Contacted&#039;
];
}

public Integer getNext30DayOppty() {
return [
select count() from Opportunity
where IsClosed = False
AND (CloseDate = Next_N_DAYS:30 OR CloseDate = TODAY)
];
}

public Integer getPastDueOppty() {
return [
select count() from Opportunity
where IsClosed = False
AND CloseDate &lt; TODAY
];
}

static testMethod void testVFController_Sidebar_Summary() {
Test.setCurrentPageReference(new PageReference(&#039;Page.SidebarSummary&#039;));
VFController_Sidebar_Summary controller = new VFController_Sidebar_Summary();
Integer i1 = controller.getUnreadLeads();
Integer i2 = controller.getNotContactedLeads();
Integer i3 = controller.getNext30DayOppty();
Integer i4 = controller.getPastDueOppty();
}

}
</pre>
<p><span style="text-decoration: underline;"><strong>Homepage HTML Component</strong></span></p>
<p>I created a component for the Narrow side and put the following HTML into the editor.  Essentially, you create an IFRAME and embed the VF page into it.  I found a (unsupported) trick on the forums to remove the developer bar from a page.  Just add <strong>?core.apexpages.devmode.url=1</strong> to the URL.  This will turn off development mode when that page is rendered.  This is important for this little iFrame page on the sidebar.  From what I&#8217;ve gathered, this hack is not supported and could change at any time.</p>
<p>The code below should work for you.  The only thing you might need to change is the Page URL if you didn&#8217;t name your page SidebarSummary and the height of it.</p>
<pre class="syntax-highlight:html">

&lt;iframe src=&quot;/apex/SidebarSummary?core.apexpages.devmode.url=1&quot; frameborder=&quot;0&quot; height=&quot;100&quot; width=&quot;100%&quot;&gt;&lt;/iframe&gt;
</pre>
<p>Let me know what you think.</p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2008/09/17/sidebar-summary-using-visualforce/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Make your Mass Email Activities more meaningful</title>
		<link>http://sfdc.arrowpointe.com/2008/07/25/make-your-mass-email-activities-more-meaningful/</link>
		<comments>http://sfdc.arrowpointe.com/2008/07/25/make-your-mass-email-activities-more-meaningful/#comments</comments>
		<pubDate>Fri, 25 Jul 2008 20:05:48 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/?p=333</guid>
		<description><![CDATA[It had always bothered me that activities generated from Mass Emails only had a subject of &#8220;Mass Email:&#8221; and nothing in the body.  I couldn&#8217;t tell what I mass emailed to someone!
Deep inside the forums, I found the trick to get some meaning into those activities.  The best you can do is get the Subject [...]]]></description>
			<content:encoded><![CDATA[<p>It had always bothered me that activities generated from Mass Emails only had a subject of &#8220;Mass Email:&#8221; and nothing in the body.  I couldn&#8217;t tell what I mass emailed to someone!</p>
<p>Deep inside the forums, I found the trick to get some meaning into those activities.  The best you can do is get the Subject filled in, but that&#8217;s something.  The subject for a Mass Email = &#8220;Mass Email: <em>Email Template <span style="text-decoration: underline;">Description</span></em>&#8220;.  Giving your email templates a description is the only way to get a meaningful mass email activity.  The Description is an often overlooked field on Email Template because it&#8217;s not required, so go make sure you have it filled in.</p>
<p><img class="alignnone size-full wp-image-334" title="email-templates-for-mass-email" src="http://sfdc.arrowpointe.com/wp-content/images/email-templates-for-mass-email.png" alt="" width="500" height="79" /></p>
<p>Once you do this, the next Mass Email you send can start having some meaning.</p>
<p><img class="alignnone size-full wp-image-335" title="mass-email-activities" src="http://sfdc.arrowpointe.com/wp-content/images/mass-email-activities.png" alt="" width="500" height="108" /></p>
<p>I created <a href="http://ideas.salesforce.com/article/show/10090971/Generate_Meaningful_Mass_Email_Activities" target="_blank">an idea on Idea Exchange</a> for what I think a better design would be.  Vote on it and comment there to improve the recommendation.</p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2008/07/25/make-your-mass-email-activities-more-meaningful/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Getting Standard Object Meta Data into the Force.com IDE</title>
		<link>http://sfdc.arrowpointe.com/2008/06/26/getting-standard-object-meta-data-into-the-forcecom-ide/</link>
		<comments>http://sfdc.arrowpointe.com/2008/06/26/getting-standard-object-meta-data-into-the-forcecom-ide/#comments</comments>
		<pubDate>Thu, 26 Jun 2008 20:03:00 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[API]]></category>

		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/?p=315</guid>
		<description><![CDATA[Salesforce on Rails has an interesting post on how you can get the meta data for standard objects into the Force.com IDE for easy manipulation of its configuration via the Meta Data API capabilities built into the IDE.
]]></description>
			<content:encoded><![CDATA[<p><a href="http://salesforceonrails.com/" target="_blank">Salesforce on Rails</a> has an <a href="http://salesforceonrails.com/2008/custom-fields-on-standard-objects-in-the-force-com-ide" target="_blank">interesting post</a> on how you can get the meta data for standard objects into the Force.com IDE for easy manipulation of its configuration via the Meta Data API capabilities built into the IDE.</p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2008/06/26/getting-standard-object-meta-data-into-the-forcecom-ide/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Derive a Rating using Formulas</title>
		<link>http://sfdc.arrowpointe.com/2008/03/27/derive-a-rating-using-formulas/</link>
		<comments>http://sfdc.arrowpointe.com/2008/03/27/derive-a-rating-using-formulas/#comments</comments>
		<pubDate>Thu, 27 Mar 2008 19:49:24 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/2008/03/27/derive-a-rating-using-formulas/</guid>
		<description><![CDATA[On a recent project, I was helping my client prioritize their lead data. They were having trouble with the default Rating field in Salesforce because 1) it required a user to populate the record and 2) the rating should change with the passing of time.
I came up with a formula that takes the Lead Status [...]]]></description>
			<content:encoded><![CDATA[<p>On a recent project, I was helping my client prioritize their lead data. They were having trouble with the default Rating field in Salesforce because 1) it required a user to populate the record and 2) the rating should change with the passing of time.</p>
<p>I came up with a formula that takes the Lead Status and Expected Close Date (a custom field) into account in order to derive a Rating value on a Lead. This client happens to use Leads for their entire sales cycle and converts Leads once they are sold, but this concept would apply to equally to Opportunities as well.</p>
<h6>Requirements</h6>
<p>The simplified requirements are to derive a Rating value as follows:</p>
<table style="font-size: 80%; width: 500px; text-align: center" cellspacing="0" cellpadding="0" border="1">
<tbody>
<tr style="font-weight: bold; color: #ffffff; background-color: #000000">
<td style="text-align: left">Lead Status / Days to Close</td>
<td>0 to 30 days</td>
<td>31 to 60 days</td>
<td>61 to 90 days</td>
<td>over 90 days</td>
</tr>
<tr>
<td style="background-color: #cccccc; text-align: left">New</td>
<td>New</td>
<td>New</td>
<td>New</td>
<td>New</td>
</tr>
<tr>
<td style="background-color: #cccccc; text-align: left">Contacted</td>
<td>Warm</td>
<td>Warm</td>
<td>Cold</td>
<td>Cold</td>
</tr>
<tr>
<td style="background-color: #cccccc; text-align: left">Interested</td>
<td>Warm</td>
<td>Warm</td>
<td>Warm</td>
<td>Cold</td>
</tr>
<tr>
<td style="background-color: #cccccc; text-align: left">Presentation</td>
<td>Hot</td>
<td>Warm</td>
<td>Warm</td>
<td>Cold</td>
</tr>
<tr>
<td style="background-color: #cccccc; text-align: left">Sent I/O</td>
<td>Hot</td>
<td>Hot</td>
<td>Hot</td>
<td>Warm</td>
</tr>
<tr>
<td style="background-color: #cccccc; text-align: left">Sold</td>
<td>Won</td>
<td>Won</td>
<td>Won</td>
<td>Won</td>
</tr>
<tr>
<td style="background-color: #cccccc; text-align: left">Lost - No Contact</td>
<td>Lost</td>
<td>Lost</td>
<td>Lost</td>
<td>Lost</td>
</tr>
<tr>
<td style="background-color: #cccccc; text-align: left">Lost - No Budget</td>
<td>Lost</td>
<td>Lost</td>
<td>Lost</td>
<td>Lost</td>
</tr>
<tr>
<td style="background-color: #cccccc; text-align: left">Lost - Not Interested</td>
<td>Lost</td>
<td>Lost</td>
<td>Lost</td>
<td>Lost</td>
</tr>
</tbody>
</table>
<p>They plan to manage their pipeline closely using the derived Rating field. They want the Rating to get &quot;better&quot; as time passes, so that they can reinforce the use of the Expected Close Date field. For example, if there is a Lead in Presentation status and it gets forgotten by Sales, that lead&#8217;s rating will eventually get to &quot;Hot&quot; as the Expected Close Date approaches or is passed. Management will be asking about that Lead and it will either be accurate or the Expected Close Date will be updated to better reflect reality. Over time, they will really be able to trust the Expected Close Date field, which is a new field for them.</p>
<h6>Solution</h6>
<p>To accomplish this, I did the following:</p>
<ol>
<li>Added a custom field on Leads called <strong>Expected Close Date</strong>. This would be filled out by the end-user and acts like the Close Date does on an Opportunity. </li>
<li>Added a custom formula field called <strong>Days to Close</strong> that calculates how many days away the Expected Close Date is. The formula is as follows:
<p style="font-size: 1.1em; margin: 10px 20px; font-family: monospace">Expected_Close_Date__c - TODAY()</p>
<p>This field was added to the Page Layout because it is pretty useful in and of itself. Also, the client is on Professional Edition, so we wanted this field available in reports and that&#8217;s how you make it visible.</p>
</li>
<li>Added a custom formula field called <strong>Rating (derived)</strong> that calculates a rating value using the requirements from the table above. I use this formula approach (using the CASE function) whenever I am doing some kind of matrixed formula result.
<div style="font-size: 1.1em; margin: 10px 20px; font-family: monospace">CASE(1,
<p>IF(ISPICKVAL( Status ,&quot;New&quot;), 1, 0),&quot;New&quot;,</p>
<p>IF(AND(ISPICKVAL( Status ,&quot;Contacted&quot;), Days_to_Close__c &lt;= 60), 1, 0),&quot;Warm&quot;,         <br />IF(AND(ISPICKVAL( Status ,&quot;Contacted&quot;), Days_to_Close__c &gt; 60), 1, 0),&quot;Cold&quot;,</p>
<p>IF(AND(ISPICKVAL( Status ,&quot;Interested&quot;), Days_to_Close__c &lt;= 90), 1, 0),&quot;Warm&quot;,         <br />IF(AND(ISPICKVAL( Status ,&quot;Interested&quot;), Days_to_Close__c &gt; 90), 1, 0),&quot;Cold&quot;,</p>
<p>IF(AND(ISPICKVAL( Status ,&quot;Presentation&quot;), Days_to_Close__c &lt;= 30), 1, 0),&quot;Hot&quot;,         <br />IF(AND(ISPICKVAL( Status ,&quot;Presentation&quot;), Days_to_Close__c &lt;= 90), 1, 0),&quot;Warm&quot;,          <br />IF(AND(ISPICKVAL( Status ,&quot;Presentation&quot;), Days_to_Close__c &gt; 90), 1, 0),&quot;Cold&quot;,</p>
<p>IF(AND(ISPICKVAL( Status ,&quot;Sent I/O&quot;), Days_to_Close__c &lt;= 90), 1, 0),&quot;Hot&quot;,         <br />IF(AND(ISPICKVAL( Status ,&quot;Sent I/O&quot;), Days_to_Close__c &gt; 90), 1, 0),&quot;Warm&quot;,</p>
<p>IF(ISPICKVAL( Status ,&quot;Sold&quot;), 1, 0),&quot;Won&quot;,</p>
<p>IF(ISPICKVAL( Status ,&quot;Lost - No Contact&quot;), 1, 0),&quot;Lost&quot;,         <br />IF(ISPICKVAL( Status ,&quot;Lost - No Budget&quot;), 1, 0),&quot;Lost&quot;,          <br />IF(ISPICKVAL( Status ,&quot;Lost - Not Interested&quot;), 1, 0),&quot;Lost&quot;,          <br />&quot;&quot;)          </p>
</p></div>
</li>
<li>The Lead Views and Reports we made for reps are driven by this derived field. By doing this, they have 1 simple value to prioritize on. Also, as new Lead Statuses emerge or if we re-define what &quot;Hot&quot; means, we only need to modify the formula. When we do, all the reports and views automatically pick it up since they are not hardcoding filters on the Lead Status of Expected Close Date fields.     </li>
</ol>
<p>Does anyone else use an approach like this? Any suggestions to make it better?</p>
<p>Depending upon complexity, it is possible to hit formula size limits. Especially considering the need to use the ISPICKVAL function for the Lead Status. <a href="http://ideas.salesforce.com/article/show/43022/The_ability_to_use_a_picklist_value_in_a_formula_field_without_ISPICKVAL" target="_blank">Vote on this idea</a> to fix the ISPICKVAL issue.</p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2008/03/27/derive-a-rating-using-formulas/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Opportunity Roll-Up Summary Recommendations</title>
		<link>http://sfdc.arrowpointe.com/2008/03/07/opportunity-roll-up-summary-recommendations/</link>
		<comments>http://sfdc.arrowpointe.com/2008/03/07/opportunity-roll-up-summary-recommendations/#comments</comments>
		<pubDate>Fri, 07 Mar 2008 07:13:12 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[Arrowpointe Maps]]></category>

		<category><![CDATA[Arrowpointe Products]]></category>

		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/2008/03/07/opportunity-roll-up-summary-recommendations/</guid>
		<description><![CDATA[Salesforce released Opportunity Roll-Up Summary fields on the Account object in the Spring 08 release.  This is a pretty useful feature and below are some recommendations to help you get started using them.
One of the major benefits of this feature is that you now get quick answers on the Accounts you are selling to [...]]]></description>
			<content:encoded><![CDATA[<p>Salesforce released <a href="http://blogs.salesforce.com/features/2008/01/opportunity-rol.html" target=_blank>Opportunity Roll-Up Summary</a> fields on the Account object in the Spring 08 release.  This is a pretty useful feature and below are some recommendations to help you get started using them.</p>
<p>One of the major benefits of this feature is that you now get quick answers on the Accounts you are selling to without having to run an Opportunity report and get multiple records for the same Account.  If you sell to a customer multiple times throughout the year, that customer will be represented once in an Account report, but will be represented multiple times (once for each sale) in an Opportunity report.</p>
<h6>Create the Fields</h6>
<p>To get started, create a new Account field and choose the <strong>Roll-Up Summary</strong> option and click Next.</p>
<p><img src="http://sfdc.arrowpointe.com/wp-content/images/rollup_summary_newfield.jpg" alt="rollup_summary_newfield.jpg" title="rollup_summary_newfield.jpg" width="450" height="184" border="0" /></p>
<p>Next, give it a name.  I&#8217;d like to recommend a <u>naming convention</u> because you will probably create multiple of these.  My personal naming convention is used in the example fields below.  For the API name, you should also use a naming convention.  This will help keep these fields together when viewed in Eclipse or Explorer.</p>
<p>After clicking Next, your options are to COUNT, SUM, MIN, MAX information from the Opportunity.  Below is a table with some ideas for fields you that might be useful:</p>
<table border="1" cellspacing="2" style="width: 90%;">
<tbody>
<tr>
<td><strong>Field Name</strong></td>
<td><strong>Rollup Type</strong></td>
<td><strong>Field to Aggregate</strong></td>
<td><strong>Filter Criteria</strong></td>
</tr>
<tr>
<td>$ Opportunities (Open)</td>
<td>SUM</td>
<td>Amount</td>
<td>Closed = False</td>
</tr>
<tr>
<td>$ Opportunities (Open - This Year)</td>
<td>SUM</td>
<td>Amount</td>
<td>1) Closed = False<br />2) Close Date = THIS YEAR <sup><a href="#fn1204872700206n" id="fn1204872700206" class="footnote">1</a></sup></td>
</tr>
<tr>
<td>$ Opportunities (Won)</td>
<td>SUM</td>
<td>Amount</td>
<td>Won = True</td>
</tr>
<tr>
<td>$ Opportunities (Lost)</td>
<td>SUM</td>
<td>Amount</td>
<td>1) Won = False<br />2) Closed = True</td>
</tr>
<tr>
<td># Opportunities (Open)</td>
<td>COUNT</td>
<td>N/A</td>
<td>Closed = False</td>
</tr>
<tr>
<td># Opportunities (Open - This Year)</td>
<td>COUNT</td>
<td>N/A</td>
<td>1) Closed = False<br />2) Close Date = THIS YEAR</td>
</tr>
<tr>
<td># Opportunities (Won)</td>
<td>COUNT</td>
<td>N/A</td>
<td>Won = True</td>
</tr>
<tr>
<td># Opportunities (Lost)</td>
<td>COUNT</td>
<td>N/A</td>
<td>1) Won = False<br />2) Closed=True</td>
</tr>
</tbody>
</table>
<h6>Using Formulas on the Rollups</h6>
<p>One really nice thing about these Rollup fields is that you can use their results in your regular formula fields.  Using the rollup fields I mentioned above, we can use formula fields on the account to create the fields such as:</p>
<ul>
<li>Win Rate (%) = # Opportunities (Won) / (# Opportunities (Won) + # Opportunities (Lost))</li>
<li>Avg Win Amount = $ Opportunities (Won) / # Opportunities (Won)</li>
</ul>
<h6>Using the Roll-Ups</h6>
<p>Now those rollup fields can come in handy in reporting to do things like:</p>
<ul>
<li>Filter for all sold-to Accounts:  $ Opportunities (Won) > 0</li>
<li>Filter for all Accounts with Open Opportunities:  # Opportunities (Open - This Year) > 0</li>
</ul>
<p>Another possiblity is in, say, <a href="http://www.arrowpointe.com/maps" target=_blank>an application that allows you to <strong>map your Salesforce.com data</strong></a>.  Adding the $ Opportunities (Won) field onto the query page makes generating a map of all sold-to accounts a breeze.</p>
<p><img src="http://sfdc.arrowpointe.com/wp-content/images/arrowpointemaps_AllWonAccounts.jpg" alt="arrowpointemaps_AllWonAccounts.jpg" title="arrowpointemaps_AllWonAccounts.jpg" width="557" height="245" border="0" /></p>
<p>What about you?  How are you using Roll-Up Summary fields?</p>
<p class="footnotes">
<p id="fn1204872700206n"><sup>1</sup> [<a href="#fn1204872700206">back</a>] - Other date filters include THIS QUARTER, THIS MONTH, LAST MONTH, NEXT YEAR, NEXT QUARTER, etc.  Refer to the Salesforce help for more.  These date filters are particularly useful for rollup summary fields.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2008/03/07/opportunity-roll-up-summary-recommendations/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Authorize logins from any IP address</title>
		<link>http://sfdc.arrowpointe.com/2007/12/10/authorize-logins-from-any-ip-address/</link>
		<comments>http://sfdc.arrowpointe.com/2007/12/10/authorize-logins-from-any-ip-address/#comments</comments>
		<pubDate>Mon, 10 Dec 2007 22:53:17 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/2007/12/10/authorize-logins-from-any-ip-address/</guid>
		<description><![CDATA[Salesforce has mostly implemented their security changes.  FYI, this is the help file page explaining to admins how to setup Network Access in the application and what happens when a user logs in.
If you have an org that you need access to without the burden of this restriction (e.g. an org you use to [...]]]></description>
			<content:encoded><![CDATA[<p>Salesforce has mostly implemented their <a href="http://sfdc.arrowpointe.com/2007/11/16/upcoming-security-changes-overview-of-impact/">security changes</a>.  FYI, <a href="https://na1.salesforce.com/help/doc/en/security_networkaccess.htm" target=_blank>this</a> is the help file page explaining to admins how to setup Network Access in the application and what happens when a user logs in.</p>
<p>If you have an org that you need access to without the burden of this restriction (e.g. an org you use to perform demos at various locations and/or from many different computers where you might not have email access), <strong>you can authorize all IPs by making 0.0.0.0 the start IP and 255.255.255.255 the end IP in a Network Access record</strong>.  </p>
<p>Doing this will essentially put that org&#8217;s security back to what it was before Salesforce made their enhancements.  I wouldn&#8217;t recommend making this change unless you actually need it, but it can come in handy even if for a short-term fix.</p>
<p>This is the approach Salesforce.com has taken for Test Drive orgs on AppExchange listings so that Test Drive users are not restricted access to a demo.  All of my Test Drives had a record with this range pre-populated by Salesforce when they made their security changes.</p>
<p><strong>Note</strong>:  I <u>do not recommend</u> anyone do this for their corporate Salesforce.com org as this would negate all the good work Salesforce has done to button things up.</p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2007/12/10/authorize-logins-from-any-ip-address/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Upcoming Security Changes - overview of impact</title>
		<link>http://sfdc.arrowpointe.com/2007/11/16/upcoming-security-changes-overview-of-impact/</link>
		<comments>http://sfdc.arrowpointe.com/2007/11/16/upcoming-security-changes-overview-of-impact/#comments</comments>
		<pubDate>Fri, 16 Nov 2007 20:29:00 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[API]]></category>

		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[News]]></category>

		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/2007/11/16/upcoming-security-changes-overview-of-impact/</guid>
		<description><![CDATA[Salesforce.com is making security changes on Monday Nov. 26, 2007. (Note that the rollout was pushed back a week from their original communications.  It is now Monday Nov. 26, 2007)
There were a couple of webinars today about the changes.  The customer-focused webinar will be available at http://www.salesforce.com/security soon.  The partner-focused one will [...]]]></description>
			<content:encoded><![CDATA[<p>Salesforce.com is making security changes on <strong>Monday Nov. 26, 2007</strong>. <em>(Note that the rollout was pushed back a week from their original communications.  It is now <strong>Monday Nov. 26, 2007</strong>)</em></p>
<p>There were a couple of webinars today about the changes.  The customer-focused webinar will be available at <a href="http://www.salesforce.com/security" target=_blank>http://www.salesforce.com/security</a> soon.  The partner-focused one will be available in the Partner Portal.</p>
<p>Below is <u>my understanding</u> of what was said and a high-level overview of the main impacts.  Please add clarifications in the comments.</p>
<h6>API Logins</h6>
<ul>
<li>If you connect via a Session ID passed from a web link/tab, none of these restrictions apply as the user is explicitly providing you with login access to his/her active session.</li>
<li>To login with a username and password, the IP address you are logging in from needs to be white-listed.</li>
<li>Salesforce will pre-populate the org&#8217;s whitelist with IPs used in the past 4 months.</li>
<li>Each end-user can generate an API token to replace their password for API logins.</li>
<li>API logins using the API token do not require their IP to be whitelisted.</li>
<li>API tokens do not expire.  Only 1 is active at a time.  It can be replaced by the user generating a new one.  This automatically invalidates the old one.</li>
<li>API tokens cannot be used to login at <a href="https://www.salesforce.com/login.jsp" target=_blank>https://www.salesforce.com/login.jsp</a>.</li>
<li>Going forward, the best practice would be for end users to provide their API token to any app/service they use other than the main Salesforce.com login page.</li>
</ul>
<h6>Logging in at <a href="https://www.salesforce.com/login.jsp" target=_blank>https://www.salesforce.com/login.jsp</a></h6>
<ul>
<li>Username and password will still be the way to access Salesforce.com from the main login page</li>
<li>A new feature will be added requiring you to confirm that your computer is valid to login using that username.</li>
<ul>
<li>The login page will check if you&#8217;ve logged in from that computer before (by looking for a browser cookie)</li>
<li>If not, the email address on the user record will be sent an email to confirm that you are, in fact, the one trying to login now.</li>
<li>You will click a link in that email &#8220;activating&#8221; your computer for login with that username</li>
<li>Unless you delete the cookie or clear your broswer&#8217;s cache, you should be good to go for a while without repeating these steps.</li>
</ul>
<li>There are no new IP restrictions affecting logins at the main login page.  The profile-based IP restrictions that have been around for a long time are still the way to go there.
</ul>
<p>If you are a consultant, you may fall victim of the new security measure when you try to login as your client (maybe they couldn&#8217;t afford another temporary username just for you).  On the call, I was told that you can request a temporary one via the Partner Portal or ask your customer to forward you the email to confirm your PC is okay.</p>
<h6>My thoughts</h6>
<p>I think it is great to see Salesforce taking a step to tighten up the API, especially.  I like to think that my old <a href="http://sfdc.arrowpointe.com/2006/11/27/api-authentication-list/" target=_blank>API Authentication List</a> post had something to do with it, but who knows.</p>
<p>The biggest impact to me will be using client&#8217;s logins to get into the system from my PC, but I&#8217;ll just have to workaround that one.  Security and convenience are generally a trade off and overall I&#8217;d rather use/subscribe to a service that is tightened down with my business data.  If anyone can handle the inconveniences of logging in, it&#8217;s developers since we are used to doing hacks/workarounds in the first place.</p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2007/11/16/upcoming-security-changes-overview-of-impact/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Sidebar Summary</title>
		<link>http://sfdc.arrowpointe.com/2007/08/28/sidebar-summary/</link>
		<comments>http://sfdc.arrowpointe.com/2007/08/28/sidebar-summary/#comments</comments>
		<pubDate>Wed, 29 Aug 2007 06:34:27 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[API]]></category>

		<category><![CDATA[Arrowpointe Products]]></category>

		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[Sidebar Summary]]></category>

		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/2007/08/28/sidebar-summary/</guid>
		<description><![CDATA[I was recently looking at Rave CRM by Entellium and I was inspired by their UI design.  I only saw the demo on their website, but they had a lot of really good UI ideas.  One of the things I really liked was a quick summary of data counts on the homepage that [...]]]></description>
			<content:encoded><![CDATA[<p>I was recently looking at <a href="http://www.ravecrm.com" target=_blank>Rave CRM</a> by <a href="http://www.entellium.com" target=_blank>Entellium</a> and I was inspired by their UI design.  I only saw the demo on their website, but they had a lot of really good UI ideas.  One of the things I really liked was a quick summary of data counts on the homepage that were very applicable to the end user.</p>
<p>I wanted to see if I could create something similar in Salesforce.  Using an s-Control that is shown via an IFRAME on the sidebar, I was able to do it.  The end result is like having a bunch of Metric style dashboard components stacked on top of each other.  You can see it in action below.  Each line shows a record count and the record count is a hyperlink to a View or Report.  It&#8217;s small, clean and tells the user vital information with quick links to see more.  I like the concept.</p>
<p><img style="margin: 0 0 0 50px;" src="http://sfdc.arrowpointe.com/wp-content/images/SidebarSummary.png" alt="SidebarSummary.png" title="SidebarSummary.png" width="353" height="310" /></p>
<h6>How it works</h6>
<p>It is all running in an s-Control and uses the AJAX toolkit to talk to Salesforce.  The s-Control is in an IFRAME in a homepage component.  The s-Control has a function called getCount and you pass getCount the following:</p>
<ul>
<li><strong>Object</strong> to Query</li>
<li><strong>WHERE clause</strong> for the query</li>
<li><strong>Label</strong> for the returned HTML</li>
<li>A <strong>URL</strong> to let a user drilldown on the result</li>
</ul>
<p>A call to it looks like this:</p>
<p><code>theHTML += getCount(&quot;Lead&quot;, &quot;WHERE IsConverted = False AND CreatedDate = TODAY&quot;, &quot;Leads - Today&quot;, &quot;/00Q?fcf=00B30000001Qizn&quot;);</code></p>
<p>It uses the object and where clause to do a count() query.  It then returns an HTML table row with 2 columns.  The first has the label you passed it in <em>italics</em>.  The second has the record count of the query as a hyperlink to the URL you passed it.  If you don&#8217;t pass it a URL, then it shows the record count without a hyperlink.</p>
<p>The s-Control is made up of 2 functions: getCount() and main().  getCount is described above.  main() calls getCount once for each metric and then wraps the results in some more HTML.  A bit of CSS is sprinkled in to output it nicely on the homepage sidebar.  That&#8217;s it.</p>
<h6>Try It</h6>
<p>I uploaded it to the AppExchange to let people try it and improve upon it.  It is just a proof of concept.  I am using it in my org right now, but it needs to be improved if I will let it stick around.  For example, it&#8217;d be great to have it cache the data and only run the queries once every 30 minutes because running it can slow the load time a bit.  Is anyone up for improving it to meet that requirement?</p>
<p>To make this work for you, you should be familiar with s-Controls.  It&#8217;s not plug and play.  Getting it setup expects you have a working knowledge of this stuff.  I kind of hacked it together and wanted to get it out there for other to see.  It&#8217;s very simple code, but I think it serves a very good purpose.  I am interested in what you think.</p>
<p><a href="https://www.salesforce.com/us/appexchange/detail_overview.jsp?id=a0330000003hUSmAAM" target=_blank><img style="margin: 0 0 0 50px;" src="http://sfdc.arrowpointe.com/wp-content/images/btnGetApps.gif" alt="btnGetApps.gif" title="btnGetApps.gif" width="190" height="50" /></a></p>
<p>I set it up with some basic queries, but I&#8217;d recommend you change them to meet your needs.  To change what the queries are, you need to go into the main() function and edit the lines that call the getCount function.  You will need a single line of code for each query you want to run.</p>
<p><img src="http://sfdc.arrowpointe.com/wp-content/images/SidebarSummary_MainFunction.png" alt="SidebarSummary_MainFunction.png" title="SidebarSummary_MainFunction.png" width="450" height="265" /></p>
<p>If you really want it to work nicely, you should create corresponding Views or Reports and link to those by passing the getCount function the URL of the View or Report.</p>
<p>Once you have your queries all set, you need to add the homepage component.  I didn&#8217;t package one in the AppExchange package because I have been unable to edit a homepage component that only has an IFRAME in it (WYSIWYG editor bug).  I&#8217;ve had to delete it and recreate it every time.  So you get to do that too!</p>
<ol>
<li>Create an HTML Area Homepage Component</li>
<li>Choose it to go on the left (narrow) navigation bar</li>
<li>Click the Show HTML checkbox on the WYSIWYG editor</li>
<li>Copy the HTML below and replace IdOfScontrol with the ID of the s-Control in your AppExchange package.  You can change the height of the IFRAME too.
<p><code>&lt;IFRAME src=&quot;/servlet/servlet.Integration?lid=<strong><u>IdOfScontrol</u></strong>&amp;amp;enc=UTF-8&amp;amp;ic=1&quot; frameBorder=0 width=&quot;100%&quot; height=&quot;150&quot;&gt;&lt;/IFRAME&gt;</code>
	</li>
<li>Add the new Homepage Component to your Homepage Layout</li>
</ol>
<p>Now you should be ready to test it out.  Using a tool like <a href="http://www.getfirebug.com/" target=_blank>Firebug</a> can greatly improve your ability to troubleshoot issues and make enhancements.</p>
<p>Please let me know what you think by posting comments.  I am interested in thoughts on the concept, ways to improve it, issues you are having, etc.</p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2007/08/28/sidebar-summary/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Fight Web to Lead Spam w/ Akismet</title>
		<link>http://sfdc.arrowpointe.com/2007/05/24/fight-web-to-lead-spam-w-akismet/</link>
		<comments>http://sfdc.arrowpointe.com/2007/05/24/fight-web-to-lead-spam-w-akismet/#comments</comments>
		<pubDate>Fri, 25 May 2007 04:10:14 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[Akismet Web-To-Lead]]></category>

		<category><![CDATA[Arrowpointe Products]]></category>

		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[Innovations]]></category>

		<category><![CDATA[Tips]]></category>

		<category><![CDATA[Wish List]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/2007/05/24/fight-web-to-lead-spam-w-akismet/</guid>
		<description><![CDATA[Back in January, I posted about a way to help combat web to lead spam.  That type of solution works well, but is not scalable.  Also, it is a reactive approach rather than a proactive one.
I decided to try and see if I could incorporate Akismet into the web to lead process and [...]]]></description>
			<content:encoded><![CDATA[<p>Back in January, I <a href="http://sfdc.arrowpointe.com/2007/01/31/stopping-web-to-lead-spam-poor-mans-way/">posted</a> about a way to help combat web to lead spam.  That type of solution works well, but is not scalable.  Also, it is a reactive approach rather than a proactive one.</p>
<p>I decided to try and see if I could incorporate Akismet into the web to lead process and I was successful in doing so!  I created a set of scripts for you to download if you&#8217;d like to leverage Akismet with your web to lead forms.</p>
<p><a href="http://www.akismet.com">Akismet</a> is the best spam tool I have ever used.  When I <a href="http://sfdc.arrowpointe.com/2007/01/31/stopping-web-to-lead-spam-poor-mans-way/">posted in January</a>, it had captured <strong>7,680</strong> spam in its existence on this blog.  Less than 4 months later, the spam count is up to <strong>23,994</strong>.  Needless to stay, spam is an exponentially increasing problem and will plague your Salesforce.com environment eventually.  I feel that Salesforce.com needs to include a spam filter in their product for web to lead (<a href="http://ideas.salesforce.com/article/show/29238" target=_blank>vote for it</a>).</p>
<p>Until then, leveraging Akismet could help you significantly.</p>
<h6>About the Solution</h6>
<p>The scripts are intended to be proof of concept for you to use and apply to your own environment.  The code and downloads are now being officially hosted at <a href="http://code.google.com/p/arrowpointe/" target=_blank>Arrowpointe&#8217;s Open Source Project at Google</a>.</p>
<p>To use this solution, you&#8217;ll point your web to lead forms to this script rather than to the standard Salesforce Web to Lead page.  The script accepts the data from your web to lead form, passes it to Akismet to determine whether it&#8217;s spam or not and then passes the data to Salesforce.com&#8217;s web to lead page with the Akismet result appended to it.</p>
<p>In Salesforce, you&#8217;ll need to add checkbox field (e.g. &#8220;Akismet marked as spam&#8221;) on your Lead.  If Akismet thinks it&#8217;s spam, that field will be set to TRUE.  You would then need to add assignment rules or validation rules to do whatever you need.  For example, you could have a lead assignment rule looking at that one checkbox field and put leads into a special queue if they are marked as spam.</p>
<p>The script leverages the <a href="http://www.achingbrain.net/stuff/akismet/">Akismet PHP5 Class</a> to handle the core communication with Akismet.  I found this class from the <a href="http://akismet.com/development/">Akismet Development page</a>.</p>
<p>This script will only work on PHP5 and requires the <a href="http://us.php.net/curl">cURL module</a> to be enabled.  cURL is enabled by default in most PHP installations.  The PHP5 requirement is a limitation of the Akismet PHP5 Class.  If you are on another platform (PHP4, Ruby, Java, etc.), I don&#8217;t see any reason why you couldn&#8217;t use these scripts and integrate a different Akismet toolkit into it.  Additional toolkits are available from the <a href="http://akismet.com/development/">Akismet Developer Page</a>.</p>
<h6>Cost</h6>
<p>You&#8217;ll need a server running PHP5.  If you have a server already setup, then hardware should cost you nothing.</p>
<p>Akismet is free for personal use, but has a small license fee for commercial use.  If you will be using this in production, you should purchase an <a href="http://akismet.com/commercial/">Akismet Commercial License Key</a>.  During development, I am sure you could use a <a href="http://akismet.com/personal/">personal key</a> to make sure it works.</p>
<p>The scripts themselves are free and licensed under the <a href="http://www.gnu.org/licenses/gpl.html" target=_blank>GNU General Public License v3</a>.  I did this as a proof of concept for the betterment of Salesforce.com data quality everywhere.</p>
<h6>Getting Started</h6>
<ol>
<li>Add a checkbox field to your Salesforce.com Lead Object that will hold whether Akismet thinks it&#8217;s spam or not.</li>
<p><img src="http://sfdc.arrowpointe.com/wp-content/images/akismet_marked_as_spam.png" alt="akismet_marked_as_spam.png" title="akismet_marked_as_spam.png" width="220" height="27" /></p>
<li><a href="http://code.google.com/p/arrowpointe/downloads/list" onClick="javascript:pageTracker._trackPageview ('/downloads/Salesforce-Web2Lead-Akismet'); "><strong>Download</strong></a> the scripts.  Three files will exist in the zip file:
<ul>
<li><strong>index.php</strong>:  The main script that handles the incoming data, talks to Akismet and posts the data to Salesforce.com Web to Lead.</li>
<li><strong>constants.php</strong>:  You will need to go into this file and edit some variable values based upon your own organizational setup.  See the next step.</li>
<li><strong>Akismet.class.php</strong>:  This is the <a href="http://www.achingbrain.net/stuff/akismet/">Akismet PHP5 class</a> I was talking about above.</li>
</ul>
</li>
<li>Edit the <strong>constants.php</strong> file:
<ul>
<li>Enter your Wordpress API key where it says ENTER_WORDPRESS_API_KEY.  Get a <a href="http://akismet.com/personal/" target=_blank>personal</a> or <a href="http://akismet.com/commercial/" target=_blank>commercial</a> key if you don&#8217;t have one.</li>
<li>Enter your company URL where it says ENTER_YOUR_COMPANY_URL.</li>
<li>Enter your company&#8217;s Salesforce.com Org ID where it says ENTER_YOUR_SALESFORCE_ORG_ID.  This is actually optional.  Doing this allows you to remove the OID from your public web to lead forms so spammers don&#8217;t know your Org ID.  Doing this will reduce the amount of spam you actually need to process.</li>
<li>Generate a web to lead form in your Salesforce setup.  Find the new Salesforce field you created in step 1 and copy the id value from the HTML form and put it in the constants.php file where it says ENTER_THE_W2L_CUSTOMFIELD_NAME.  This step is required so that your Salesforce org is actually populated with the Akismet result.</li>
<li><em>PHP Advanced</em>:  The $Akismet_noPass array holds the names of fields that should <u>not</u> be included in the content passed to Akismet.  Feel free to add/remove values from this array.  The values in the array are referring to the names of form fields in your web to lead HTML form.  I have no idea if this helps/hurts, but it seemed like a practical thing to add into the script.</li>
</ul>
</li>
<li>Upload the scripts to your web server and note the fully qualified URL for that directory (e.g. http://www.example.com/web2lead)</li>
<li>Update your web to lead forms to have them post to the location of the files from the previous step (e.g. http://www.example.com/web2lead/ - make sure to put the / at the end of the URL.  Not sure why, but I wasn&#8217;t able to get it to work without it)</li>
<li>Test your form to see if it works.  The script acts as an intermediary between your form and Salesforce web to lead.  The end-user experience should be the exactly the same with or without the scripts.</li>
<li>Once you know it works, you should add a lead assignment rule into Salesforce as rule #1 that looks to see if this field is checked.  If so, then route the lead to a &#8220;Potential Spam&#8221; queue or something of that nature.  Another option is to create a validation rule that doesn&#8217;t even allow the lead into the system.</li>
<li>Make sure your Auto Response rules don&#8217;t email a reply to leads marked as spam.  If you allow this, then those spammers have an email address to try.</li>
<li>Update some/all of your web to lead forms to post to this new page.  If desired, remove the &#8220;oid&#8221; field from the HTML form for each of these since the script will pass your Org ID to Salesforce automatically.</li>
</ol>
<h6>Other Stuff</h6>
<p>These scripts are a proof of concept.  I am not officially supporting them, but am happy to help people out informally.  Post comments here if you have questions/comments/criticisms.</p>
<p>I have only tested this with leads that were either real or very obviously spam.  It worked well.  From Akismet&#8217;s perspective, the data it checks looks just like a blog comment and I can attest that Akismet is amazing at identifying blog comment spam.  So it should work well for Salesforce.com web to lead.</p>
<p>I am going to update my existing web to lead forms on this site and see how it works and report back to you.  I encourage you to do the same and let me know your experiences with it or recommendations on how to improve the scripts.</p>
<p>Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2007/05/24/fight-web-to-lead-spam-w-akismet/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Use a List button to POST data to an external page</title>
		<link>http://sfdc.arrowpointe.com/2007/05/02/use-a-list-button-to-post-data-to-an-external-page/</link>
		<comments>http://sfdc.arrowpointe.com/2007/05/02/use-a-list-button-to-post-data-to-an-external-page/#comments</comments>
		<pubDate>Thu, 03 May 2007 01:02:26 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/2007/05/02/use-a-list-button-to-post-data-to-an-external-page/</guid>
		<description><![CDATA[This is actually more of a lesson in JavaScript, but it shows how flexible the Salesforce environment can be to meet various requirements.  The ability to add &#8220;OnClick JavaScript&#8221; behind a button is a really nice feature.
My requirements were:

Ability for an end user to, from an Account view, check the records that need to [...]]]></description>
			<content:encoded><![CDATA[<p>This is actually more of a lesson in JavaScript, but it shows how flexible the Salesforce environment can be to meet various requirements.  The ability to add &#8220;OnClick JavaScript&#8221; behind a button is a really nice feature.</p>
<p>My requirements were:</p>
<ol>
<li>Ability for an end user to, from an Account view, check the records that need to be processed and click a button to process them.</li>
<li>The processing is to take place in an external PHP page</li>
<li>Pass the parameters as an HTTP POST transaction (i.e. do NOT include the parameters in the URL string).</li>
</ol>
<p>I knew I would need to create a custom List button so that it could appear above the view.  I used the OnClick JavaScript option because what I needed to do was simple and I didn&#8217;t want the overhead of an s-Control getting invoked.  That solves <strong>requirement #1</strong>.</p>
<p><img src="http://sfdc.arrowpointe.com/wp-content/images/list_button_setup.png" alt="list_button_setup.png" title="list_button_setup.png" width="450" height="168" /></p>
<p><strong>Requirement #2</strong> could be solved by having the button use 2 lines of JavaScript to pass the parameters to the PHP page.</p>
<blockquote><p>
idArray = {!GETRECORDIDS($ObjectType.Account)};</p>
<p>window.open(&#8221;https://www.mydomain.com/script.php?session={!API.Session_ID}<br />
&#038;server={!API.Partner_Server_URL_90}&#038;idArray=&#8221;+idArray);
</p></blockquote>
<p>This got the job done, but <u>violates requirement #3</u>, which is to keep the data sent to the page hidden from view.</p>
<p><strong>To meet requirement #3</strong>, I had to use JavaScript to dynamically build an HTML form on the fly, add data to it and then submit it.</p>
<blockquote>
<p><strong>// create the form. Set it up to POST the transaction</strong><br />
f = document.createElement(&#8221;form&#8221;);<br />
f.action=&#8221;https://www.mydomain.com/script.php&#8221;;<br />
f.method = &#8220;post&#8221;;<br />
f.target = &#8220;_blank&#8221;;</p>
<p><strong>// add the session id as a parameter</strong><br />
i = document.createElement(&#8221;input&#8221;);<br />
i.id = &#8220;session&#8221;;<br />
i.name = &#8220;session&#8221;;<br />
i.type = &#8220;hidden&#8221;;<br />
i.value = &#8220;{!API.Session_ID}&#8221;;<br />
f.appendChild(i);</p>
<p><strong>// add the server location as a parameter</strong><br />
i = document.createElement(&#8221;input&#8221;);<br />
i.id = &#8220;server&#8221;;<br />
i.name = &#8220;server&#8221;;<br />
i.type = &#8220;hidden&#8221;;<br />
i.value = &#8220;{!API.Partner_Server_URL_90}&#8221;;<br />
f.appendChild(i);</p>
<p><strong>// Get the Account IDs that were checked</strong><br />
idArray = {!GETRECORDIDS($ObjectType.Account)};</p>
<p><strong>// add the idArray as a parameter</strong><br />
i = document.createElement(&#8221;input&#8221;);<br />
i.id = &#8220;idArray&#8221;;<br />
i.name = &#8220;idArray&#8221;;<br />
i.type = &#8220;hidden&#8221;;<br />
i.value = idArray;<br />
f.appendChild(i);</p>
<p><strong>// add the form to the document.</strong><br />
document.body.appendChild(f);</p>
<p><strong>// submit the form</strong><br />
f.submit();</p>
</blockquote>
<p>This solution worked perfectly.  The end result was that the PHP page the form posted to was able to retrieve the Salesforce session Id, endpoint location and an array of Id values via the $_POST variable and none of those parameters were visible in the URL.  The PHP was opened in a new window, which was defined in the <em>f.target = &#8220;_blank&#8221;;</em> line above.</p>
<p>I don&#8217;t know if there&#8217;s an easier way to do this or not (comments are welcome), but this turned out to be very easy and is an approach I will re-use.  The hardest part was trying to figure out the JavaScript syntax.</p>
<p>This is a nice trick for non-Salesforce JavaScript development too.</p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2007/05/02/use-a-list-button-to-post-data-to-an-external-page/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Schedule your Apex logic</title>
		<link>http://sfdc.arrowpointe.com/2007/04/17/schedule-your-apex-logic/</link>
		<comments>http://sfdc.arrowpointe.com/2007/04/17/schedule-your-apex-logic/#comments</comments>
		<pubDate>Wed, 18 Apr 2007 05:45:17 +0000</pubDate>
		<dc:creator>Scott Hemmeter</dc:creator>
		
		<category><![CDATA[APEX Code]]></category>

		<category><![CDATA[Configuration]]></category>

		<category><![CDATA[The Community]]></category>

		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://sfdc.arrowpointe.com/2007/04/17/schedule-your-apex-logic/</guid>
		<description><![CDATA[Steve over at gokubi.com  has been doing a lot with Apex Code recently.  He has a clever post about writing Apex code triggers and having them run on a schedule.  It&#8217;s a good post to get the wheels turning with regards to what you can now do on the platform.
Nice work, Steve.
]]></description>
			<content:encoded><![CDATA[<p>Steve over at <a href="http://www.gokubi.com">gokubi.com</a> <a href="http://gokubi.com/archives/category/technology/crm/feed"><img src="http://sfdc.arrowpointe.com/wp-content/images/feed-icon-12x12.png" alt="feed-icon-12x12.png" title="feed-icon-12x12.png" width="12" height="12" /></a> has been doing a lot with Apex Code recently.  He has a <a href="http://gokubi.com/archives/daily-cron-jobs-with-apex">clever post</a> about writing Apex code triggers and having them run on a schedule.  It&#8217;s a good post to get the wheels turning with regards to what you can now do on the platform.</p>
<p>Nice work, Steve.</p>
]]></content:encoded>
			<wfw:commentRss>http://sfdc.arrowpointe.com/2007/04/17/schedule-your-apex-logic/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
