+ Start a Discussion
chrismclarenchrismclaren 

Visualforce Datatable problem with background

I have a visualforce page that has a records data displayed as a PDF.  The background for the columns on the left need to be blue.  However using a CSS file it is only ht e text background that turns blue.  The rest of the cell has a white background.  Looking on the internet it might be that the <DIV> tags screw this up.  Anyway I need to have the entire cell background in blue, any help appreciated.

 

 

<apex:page controller="CVRRead" showHeader="false" sidebar="false" renderas="pdf">
<apex:stylesheet value="{!$Resource.CVR_CSS}">

<apex:form >
<apex:sectionHeader title="Business Development" />

       <apex:dataTable value="{!solution}" var="o" id="theTable" border="1" columnsWidth="100px, 140px" >

                <apex:facet name="caption">Client Visit Report</apex:facet>

                <apex:column >
                        <apex:outputText value="Client Visit Report" styleclass="CVRTable"/>                     
                </apex:column>

                <apex:column >
                        <apex:outputText value="{!o.SolutionName}" styleclass="CVRData"/>
                </apex:column>

        </apex:dataTable>

       <apex:dataTable value="{!solution}" var="o" id="theTable2" border="1" columnsWidth="100px, 140px">
                <apex:column >
                        <apex:outputText value="Meeting Objective" styleclass="CVRTable"/>                     
                </apex:column>

                <apex:column >
                        <apex:outputText value="{!o.Meeting_Objective__c}" styleclass="CVRData"/>
                </apex:column>

        </apex:dataTable>
        
       <apex:dataTable value="{!solution}" var="o" id="theTable3" border="1" columnsWidth="100px, 140px">
                <apex:column >
                        <apex:outputText value="Visual Process" styleclass="CVRTable"/>                     
                </apex:column>

                <apex:column >
                        <apex:outputText value="{!o.Visit_Process__c}" styleclass="CVRData"/>
                </apex:column>

        </apex:dataTable>


</apex:form>
</apex:stylesheet>
</apex:page>
                                        

 

 

chrismclarenchrismclaren

Really sorry, just figured it out.  For those who ever get the same error this is what you need to change (remember to take out any other references to the CSS)

 

       <apex:dataTable value="{!solution}" var="o" id="theTable" border="1" columnClasses="CVRTable, CVRData" columnsWidth="100px, 140px">