Record Types

Record Types are hard to get your head around but are so super powerful that you need to understand them well, and use them - everywhere.

Record Types go hand in hand with Rules for Page LayoutsProfiles,  Opportunity stages.

Record Types are only available in Enterprise and up. As with Workflows, and the  API it is the main reason to use Enterprise. 

Record Types Help document https://help.salesforce.com/apex/HTViewHelpDoc?id=customize_recordtype.htm&language=en

Uses

  • Different fields on the same form. Eg Clients have different fields than Suppliers
  • Different fields for different stages of the Lead or Opportunity. Eg only a few fields on the initial lead form from the Web Enquiry, but more fields when it reaches the Contacted stage. 
  • Different page layouts for different Profiles - eg Sales sees different fields from Admins.
  • Different picklist values for different records - eg Client Account Type may be different than Supplier Account Types. 

Steps

Create the Page Layouts

  • Copy the existing page layout and modify it to suit the record type it will be used for. 

  • Name the page layouts to suit the record type. 

Create the Record Types

  • The description is very important as that is what the user sees when creating a new record. 
  • Remember to set it to be active.
  • The Profile selection is very important also - it is easiest to set it up here. 
    • First screen is the Profiles that can use that Record Type
    • Second Screen is the default Record Type for that profile. 
  • Save the Record Type

Set the Picklists

We are choosing which picklist values are NOT going to be included for this Record Type. This is usually appropriate for different Lead or Opportunity stages that may be different for different Sales Processes that you do - eg selling widgets has different profiles than selling services. 

Do the Page Layout Assignment

Now come back to the Record Types menu and click on the Page Layout Assignment button. 

This screen is difficult to understand, but once you do it becomes quite easy. It is harder to understand with more record types. 

This is where the naming of the page layouts is crucial. If your page layouts are named Clients - Sales and Clients - Admin, then it is easy to set the page layouts to the right record type (clients) and the right profiles (sales or admin). 

It's a 3 way relationship

  • Record Types to Profiles - we set that in the wizard
  • Record Types to Page Layouts - we are setting that in this screen
  • Page Layouts to Profiles - we set the default in the wizard??

All of these combined, work out which page layout will be displayed to the user.

Note about setting the default so not having the modify the PLA.

Modify the Page Layouts

Now we are going to put the record type field on the page layouts. Remember to add it to each page layout in exactly the same position. 

 

Your record types are now set up. 

The next step is to extend the Record Types with workflows. 

  • This allows you to automatically change the page layout when the stage of the Lead or Opportunity changes. 

 

Notes

  • Page layouts on their own are a bit useless because there is no way to change the page layouts. The only way to change a page layout is to change the record type, and the page layout is associated with that record type. 
  • If you only have one record type plus the master, once you change the record from the master to the record type, you can't (easily?) change it back. So have two record types.