function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
VanyaRVanyaR 

How to Html email based on existing VF custom page layout using custom controller

All,

 

I would like to send a VF custom page out as an HTML email, re-using both the VF page code and the custom controller code.  Any suggestions?  Current solution:  Built up HTML string loosely based on the VF page using the custom controller and assigned it as the email body in an apex class.  Not getting to use any of the SF automation.

magdielhfmagdielhf

I'm not 100% sure,

 

but i think this post it's a good start for what are you looking for

 

http://community.salesforce.com/sforce/board/message?board.id=apex&thread.id=24750

 

Maybe creating a visual force email template with the basic HTML structure you need, and later include CSS style sheets and controller logic using  visual force components