+ Start a Discussion

How to get a custom controller that mimics standard controller?

I have a VF page that uses a standard controller.  Now, I have to turn it into a custom component in order to be able to use it in a VF email template.  Since custom components cannot use standard controllers, does that mean that I have to write a custom controller that does everything the standard controller was already doing for me?  Or, can I extend the standard controller somehow using the apex:component tag?  (All the examples of controller extensions I see are related to pages that use the extensions parameter.  I haven't seen any related to a component, other than this thread that ended unsolved.)  

In particular, I'd *really* like to not have to recreate the handling of opportunity line items that comes for free with the Opportunity standard controller.