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

Formatting the font using <apex:outputField>

Hi Guys,


I am playing around with VisualForce and PDF rendering. Basically I have a custom object called 'Meeting Reports' and I want to create a custom link called 'Minutes' that references the information in the object and produces the minutes in pdf format.


I am however having a problem with <apex:ouputField> whereby I can't seem to set the font size despite reference a style. The field I am referencing is Rich Text and I want to retain bulletting etc (which apex:outputText doesn't allow). Unfortunately the VisualForce page displays the text in a huge font.


Any ideas???


<apex:page renderAs="pdf" standardController="Meeting_Report__c">
     body {font-family: Arial Unicode MS;}
     .companyName {
        <apex:image url=""/>
        <h1>Meeting Minutes</h1>
                <apex:panelGrid columns="2" width="100%">
                        Client:          <apex:outputField value="{!Meeting_Report__c.Account__c}" />
                        Date / Time:    <apex:outputField value="{!Meeting_Report__c.Date_and_Time__c}" />
                        Location:          <apex:outputField value="{!Meeting_Report__c.Location__c}" />
        <apex:panelGrid columns="1" width="100%">
                <apex:outputText value="{!Meeting_Report__c.Purpose__c}" styleClass="companyName"/>
                <apex:outputField value= "{!Meeting_Report__c.Report__c}" styleClass="companyName"/>