Skip to main content

 The Standard Object "Contract" has a field "FileName_c". 

I want to set the file name(Contract.FileName_c) to be saved in "Save as" when a PDF is created.

I found some solution from this site and salesforce.stackexchange.com. But I cannot resolve.

What code enter to my Vis

 

#PDF #PDFs #Visualforce Pages #Generate Document #Dynamic #Sales Cloudualforce Page and Apex Class? My codes are below.

///Visualforce Page///

<apex:page renderAs="pdf" applyhtmltag="false" showheader="false" standardController="Contract" extensions="ContractController">

/ my main code is here /

<head>

<style>

 

///Apex Class///

 public class ContractController{       // my main code is here //

    private final Contract contract;     public Contract tokuyaku {get;set;}     public String tokParts{get;set;}     public String tokTime{get;set;}     public String Remarks{get;set;}     public String season{get;set;}     public String tokuSp{get;set;}          public ContractController(ApexPages.StandardController stdController){         this.contract = (contract)stdController.getRecord(); 

3 answers
0/9000