0
 <apex:pageblockSection columns="3" var="account">
                <apex:pageblockSectionItem >
                <apex:outputLabel value="Account Name"/>
                <apex:inputtext value={!a.name}/>
                </apex:pageblockSectionItem>
                <apex:pageblockSectionItem >
                <apex:outputLabel value="City"/>
                <apex:inputtext value={!a.city}/>
                </apex:pageblockSectionItem>
                <apex:pageblockSectionItem >
                <apex:outputLabel value="Country"/>
                <apex:inputtext value={!a.adress}/>
                </apex:pageblockSectionItem>

            </apex:pageblockSection>

I have displayed the output correctly. But i need to make this same output with the use of apex repeat tag. Can I do that ? If yes , please help me out since i want to reuse the code dynamically in future if needed

0

This is the way you can proceed for <apex:repeat>. You need to use own CSS for look and feel. Refer apex:repeat at documentation.

<table style="width:100%" id="table1" border="1"> 
     <tr>
        <th>Account Name</th>
        <th>City</th>
        <th>Country</th>
      </tr>                
    <apex:repeat id="repeat1" value="{!account}" var="a">
       <tr>
        <td><apex:inputtext value={!a.name}/></td>
        <td><apex:inputtext value={!a.city}/></td> 
        <td><apex:inputtext value={!a.adress}/></td>
      </tr>                       
  </apex:repeat>
</table> 

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.