skip to main
|
skip to sidebar
Visual Force
Wednesday, December 3, 2008
PDF Save in Attachment
Controller Code:
public void showPDF() { PageReference savePDF= new PageReference('/apex/ProposalPdf?id='+apexpages.currentpage().getparameters().get('id')); Blob pdfBlob = savePDF.getContent(); Attachment saveAtch = new Attachment(ParentId = apexpages.currentpage().getparameters().get('id'), Name = prop.Name+'.pdf' , ContentType = 'pdf', Body = pdfBlob); insert saveAtch; }
Newer Posts
Older Posts
Home
Subscribe to:
Posts (Atom)
Blog Archive
▼
2008
(4)
▼
December
(1)
PDF Save in Attachment
►
November
(2)
►
September
(1)
View My Stats
About Me
Visual Force
View my complete profile