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
Kim GrondsmaKim Grondsma 

Sort order of PDF different from quote page?

I have created a visualforce page to render a good looking qoute PDF 
This work, all the styling is exactly what I want. 
However when rendering the PDF the Quote line items appear in a different sort order than they are sorted on the qoute detail page in the related list. 
How can I have the PDF display the same order? 
Because the styling is the main reason I reverted to PDF I would like t stick with the code for the table, just add something to control the sorting

This is my visualforce page code: 
  <td style="width: 13%; text-align: center; font-size: 10pt;"><apex:outputText value="{0, number, integer}">
    <apex:param value="{!line.Quantity}"/> </apex:outputText></td>
           <td style="width: 44%; font-weight:bold; font-size: 10pt;"><apex:outputField value="{!line.Product2.Name}" /></td>

             <td style="width: 20%; text-align: right; font-size: 10pt;"><apex:outputField value="{!line.UnitPrice}" /></td>

             <td style="width: 20%; text-align: right; font-weight:bold; font-size: 10pt;"><apex:outputField value="{!line.TotalPrice}" /></td>

              <td></td> 

         </tr>
         <tr>
         <td></td>
         <td font-size=" 10pt" margin-right= "0.5cm" ><apex:outputField value="{!line.Product_description__c}" /></td>
         </tr>
         <tr>
         <td colspan="5" class="bottomborder"> </td> </tr>

         </apex:repeat>  
ShashankShashank (Salesforce Developers) 
If you notice that the quote line items are sorted by product, it is probably due to this limitation: https://success.salesforce.com/ideaView?id=08730000000YHmBAAW