Posts tagged ‘help from my friends’

January 10, 2014

Small but Mighty

just-say-never-doubt-for-all-condition-margaret-mead-quotes-margaret-mead-quotes-never-doubt-936x936

OK, so maybe a small group of citizens doesn’t apply here. But what about a small group of fields? Oh perhaps even just one simple field.

This is a field that I’ve added to many orgs that I’ve worked with, and shared with even more admins who have added it to theirs as well. It’s a field that several Salesforce MVPs have their own twist on. A field that when I tell folks about it, I get some pretty amazing reactions, especially for companies that have high-touch processes. And I can’t believe that it took me 4 years of working with Salesforce before I thought to make this field – and once you hear it, I bet that you will think that same thing.

So what’s the field? A time-zone formula field for Leads, Contacts and Accounts (and really, any other object you what to throw it on). Now you want the formula, right?

read more »

January 25, 2013

Begin at the beginning

“Begin at the beginning,” the King said, very gravely, “and go on till you come to the end: then stop.” ~ Lewis Carroll, Alice in Wonderland

This post actually has nothing to do with beginnings. Or endings for that matter. What it really has to do with is the rabbit hole that is the internet, and how I don’t think that such a bad thing.

alice-in-wonderland_2-1800-670x309

read more »

October 5, 2012

Dreamforce Debrief

Two weeks later, and I feel like I’m finally back in a routine. That’s what Dreamforce does to me. The weeks leading up to it are filled with anticipation and excitement, and then afterwards, it takes me two weeks to digest and absorb everything that I learned. It’s a bit crazy if you think about it.

So what did I learn?

read more »

October 7, 2011

You know that I could use somebody…

Yesterday, Boston hosted the largest Salesforce user group ever! There were 426 registrants, and we packed the ballroom at the Seaport Hotel. In attendance, we had everyone from new Salesforce prospects, to C-level executives at some of the leading companies in the area. We had attendees coming from Rhode Island, Vermont, Maine, North Carolina and even a surprise guest all the way from Salesforce HQ in San Francisco.

Boston User Group - credit to @knthornt

I’ve written about the user groups in the past, (and that post wasn’t a huge success). But I’m going to try it again, because I feel so strongly about what these groups offer to those who attend the meetings.

Of course there is the free breakfast and the potential to get some swag, but that’s not why I go. It’s that chance to network, to share some of the things I know, and to see innovative things that others are doing with the platform. I go to see the vendors, and explore new ways to expand functionality. I guess you could say that I go to teach, and to learn.

With over 140 groups worldwide, there is no reason why you shouldn’t be attending. And yes, not every group is as large or as organized as Boston. But it got that way because there are passionate people attending our meetings. What’s to stop you from doing the same?

May 13, 2011

Trigger Happy!

I talk a lot about the ‘auto-magic’ in salesforce.com, but we all know it has it’s limitations. One of the things that I always wished could be done with button-clicking was to create a new record when conditions on another record were met (ya know, using some workflow powers). I really just considered myself out of luck.

That is until I started dabbling in the developer world. And while I consider myself knowing just enough to causing catastrophic damage, a business case presented itself in which trying out my new skills was the perfect fit. In short, the team wanted a record auto-created every time a specific type of event was created.

Here it is, my debut into triggers (excluding my copy-edit-paste of one from MichaelForce):

trigger createPDtask on Event (after insert) {     
List<Support_Request__c> sr = new List<Support_Request__c>();
    for (Event newEvent: Trigger.New)
         if (newEvent.Type__c == '1. Meeting - Initial'){
                 sr.add (new Support_Request__c(
                     Name = 'New PD',
                     Task_Type__c = 'PD',
                     SFDC_Record_ID__c = newEvent.Id,
                     Rep__c = newEvent.OwnerId,
                     Event_Date__c = newEvent.ActivityDate));   
         }
   insert sr;
 }

So there it is. Short & fairly simple, but a HUGE productivity win. Plus, now everyone thinks I’m magic! And if you want a deeper dive explanation on the anatomy of this trigger, read my post on the Teach Me Salesforce blog!

UPDATED!! Here is my test class (Huge thanks to Kyle for help with the System.assertEquals bit:

@isTest private class createPDtask_Test { 
   private static testmethod void testTriggerForEvent(){         
 Event e = new Event();   
               
 //Required Fields         
 e.Subject = 'testSubject';         
 e.IM_Type__c = '1. Meeting - Initial';         
 e.Product_Interest__c = 'None';         
 e.StartDateTime = DateTime.NOW();         
 e.EndDateTime = DateTime.NOW()+1;                  


 //Insert the Record         
 insert e;                  


 //Query for Inserted SR         
 List<Support_Request__c> testRequests = [SELECT id FROM Support_Request__c             
 WHERE SFDC_Record_ID__c = :e.Id];                      


 //We expect one record to be created         
 System.assertEquals (1, testRequests.size());        
 } 
}
%d bloggers like this: