You need to sign in to do that
Don't have an account?

how to add row in visual force page
HI my visual force page will be following

my requirement is if same Agreement name is there and different drivers are there then i want to display only one name with rowspans . and i want to add subtotals(row) for each Agreement name . my page shoul like

how can i do rowspan according to drivers count. my vf page code is
my requirement is if same Agreement name is there and different drivers are there then i want to display only one name with rowspans . and i want to add subtotals(row) for each Agreement name . my page shoul like
how can i do rowspan according to drivers count. my vf page code is
<apex:page controller="header" showHeader="false"> <style> table { border-collapse: collapse; } table, td, th { border: 1px solid black; width:20%; } </style> <apex:form id="theform" > <apex:pageBlock > <table> <tr > <th >Agreement Name</th> <th>Driver</th> <apex:repeat value="{!agrmnts}" var="c"> <td colspan="2" style="text-align:center"> <apex:outputText value="{!c}"></apex:outputText> </td> </apex:repeat> </tr> <tr> <th></th> <th></th> <apex:repeat value="{!agrmnts}" var="c"> <th>Quantity</th> <th>Sale</th> </apex:repeat> </tr> <apex:repeat value="{!body}" var="bd"> <apex:variable value="{!0}" var="index"/> <tr> <apex:repeat value="{!bd}" var="cd"> <td> <apex:outputText value="{!cd}" rendered="{!IF(index < 2,'true','false')}"></apex:outputText> <apex:commandLink action="{!method}" reRender="theform" status="mystatus" value="{!cd}" rendered="{!IF(index >= 2,'true','false')}"> <apex:param value="{!bd[0] }" assignTo="{!Agreename}" name="AG"/> <apex:param value="{!bd[1] }" assignTo="{!drive}" name="dr"/> <apex:param value="{!index }" assignTo="{!indx}" name="in"/> </apex:commandLink> </td> <apex:variable var="index" value="{!index+1}"/> </apex:repeat> </tr> </apex:repeat> </table> </apex:pageBlock> </apex:page>what changes i should made. how data i should send inorder to do row span