Dec 14
S-Control Example
icon1 James Sullivan | icon2 Salesforce.com | icon4 12 14th, 2006| icon3No Comments »

When I started developing AJAX S-Controls I looked everywhere for a good, simple example. Something simple enough to illustrate the mechanics of the process while still being functional. Someone came to me looking for the same thing but now all my S-Controls are hundreds of lines long, so they’re not a simple example.  I made a simple example of an S-Control that prints out the open leads belonging to my user. For each lead, there is a button that allows you to update the status to “Closed Lost”. I based it off this very popular blog post from the SF-Blog. Here it is:  20061214-code.txt

Dec 14

You don’t have to wait for the Winter 2007 release of Salesforce.com to take advantage of approval processes. That’s right – you can do it now using the existing functionality. All you need is a custom field on the activity object and you can make workflow rules to accomplish virtually any approval process. Here’s how:

Enter setup (you must be an admin) and navigate to “App Setup” > “Customize” > “Activities” > “Custom Fields”:
20061213nav.jpg

Now, create a custom field here titled “Workflow_ID” as a text field with length of 50. This field will record the be used to trigger your workflows. The system will ask if you want this field shown or editable by anyone. I suggest that it’s visible to admin but not editable by anyone else. Personally, I haven’t found reason to include it in a layout.
With this custom field, you can now create workflow chains. Where you once had three check-boxes that held the different levels of completion for approvals on a record, you can have the one task workflow handle this. Let’s take Opportunity close as an example.

In an example situation, an Opportunity must be approved by legal before going to finance. A task is created as a template for the legal review. On this task, since you’re admin, populate the Workflow_ID field with “OPPTY_APPROVAL_STEP_1″.

Now, create a workflow rule assigning this task to the finance guy when the Opportunity closes. Great, now you’ve got a legal approval – finance needs to know when it’s complete.

Next step, create a new workflow based off the “Task” object with criteria related to the Workflow_ID field. Use the following criteria:

Workflow_ID , equals , OPPTY_APPROVAL_STEP_1
Status , equals , Completed

Now, when that task is closed, this rule can be triggered. Follow the steps above with a different Workflow_ID key and you have task-based workflow.

Dec 12
Time Sheets In Salesforce.com
icon1 James Sullivan | icon2 Uncategorized | icon4 12 12th, 2006| icon31 Comment »

The professional services department wants to track time sheets in a central location. We use Salesforce.com for everything else, why not time sheets?

The only way to do it out-of-the-box requires the users to open a new record and perform the data entry on a single page for each time allocation. This means a lot of clicking. A lot.

I got around this by creating an AJAX S-Control that retrieves the time-sheet records (a custom object) and populates them in a grid along with a few blank rows at the bottom for ample area to account for today’s new time records.

The projects list is a list of Opportunities that they can attribute their work to.

Take a look, what do you think?

my-time-sheets.jpg