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
aditya3aditya3 

Regarding OutputLink

Hi All,
I am trying to put outlink for the name of the Account  as Displayed in a List ,THe code is as follows ,Please help me how to modify that how to add outputlink
<apex:dataTable value="{!acclist}" var="ac" cellpadding="4" border="2">
<apex:column headerValue="Name" value="{!ac.name}"/>
<apex:column headerValue="Phone" value="{!ac.Phone}"/>
<apex:column headerValue="Industry" value="{!ac.Industry}"/>
<apex:column headerValue="Type" value="{!ac.Type}"/>
<apex:column headerValue="Employees grc" value="{!ac.NumberOfEmployees}"/>
</apex:dataTable>
Best Answer chosen by aditya3
sandeep sankhlasandeep sankhla
Hi aditya,

Replace your name column with below code

<apex:column>
<apex:outputLink value="{!ac.name}">{!ac.name}
</apex:outputLink>
</apex:column>

P.S. If my answer helps you to solve your problem please mark it as best answer. It will help other to find best answer.

Thanks,
Sandeep
Salesforce Certified Developer 

All Answers

sandeep sankhlasandeep sankhla
Hi aditya,

Replace your name column with below code

<apex:column>
<apex:outputLink value="{!ac.name}">{!ac.name}
</apex:outputLink>
</apex:column>

P.S. If my answer helps you to solve your problem please mark it as best answer. It will help other to find best answer.

Thanks,
Sandeep
Salesforce Certified Developer 
This was selected as the best answer
aditya3aditya3
How to draw table in vf page ?as my code is like this
<apex:pageBlock >
<apex:pageblockSection collapsible="false">
<apex:outputLabel value="Partnership Management    :   Toyota  Material  Handling  (USA)" styleClass="hdval"></apex:outputLabel>
<apex:outputLabel value="Billing Address           :  National HeadQuarters,USA "></apex:outputLabel>
<apex:outputLabel value="Industry                  :  Ind  Powered  vehicles Mfg " styleClass="hdval"></apex:outputLabel>
<apex:outputLabel value="Shipping Address          : National Headquarters ,USA" styleClass="hdval1"></apex:outputLabel>
<apex:outputLabel value="Phone :9176153820" styleClass="hdval"></apex:outputLabel>
</apex:pageblockSection>
</apex:pageblock>
sandeep sankhlasandeep sankhla
Hi aditya,

How you want your values to display on VF page..How many column and rows ?

you can simply sue table structore

<Table>
    <tr>
          <td></td>
    </tr>
    <tr>
          <td></td>
    </tr>
     <tr>
          <td></td>
     </tr>
</Table>

Now you can put the values in these Td's if you need 2 columsn then simply you can use to td in one row..

Thanks,
Sandeep