• santhi sanapala 5
  • NEWBIE
  • 20 Points
  • Member since 2017

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 1
    Replies
hi ,

i've written a code to show account details but its not working.kindly help as it is not throwing any error and there is also data in list<Account> in apex class.

Vf code :

<apex:page controller="accountInformation">
<apex:pageblock title="Accounts" >
<!--
<apex:repeat value="{!accs}" var="a">
<apex:pageblocksection >
<apex:outputlabel value="{!a.Name}"/>
<apex:outputfield value="{!a.Phone}"/>
<apex:outputfield value="{!a.Active__c}"/>
<apex:outputfield value="{!a.CleanStatus}"/>
</apex:pageblocksection>
</apex:repeat>
-->
<apex:pageblockTable value="{!accs}" var="a">
<apex:column value="{!a.Name}"/>
<apex:column value="{!a.Phone}"/>
<apex:column value="{!a.Active__c}"/>
<apex:column value="{!a.CleanStatus}"/>

</apex:pageblockTable>

</apex:pageblock>


</apex:page>

apex class:

public class accountInformation {


public list<Account> accs{ get; set;}

public list<Account> getAccounts(){

accs=[select Name,Phone,Active__c,CleanStatus from Account];
system.debug('Account info:'+accs);
return accs;
}

}
i have created a student object (child object ) which is in master detail relationship with Course object (parent ) and Student object is not visible in OWD. Why is this? If i want to edit OWD settings of Student object how is that possible.?
hi ,

i've written a code to show account details but its not working.kindly help as it is not throwing any error and there is also data in list<Account> in apex class.

Vf code :

<apex:page controller="accountInformation">
<apex:pageblock title="Accounts" >
<!--
<apex:repeat value="{!accs}" var="a">
<apex:pageblocksection >
<apex:outputlabel value="{!a.Name}"/>
<apex:outputfield value="{!a.Phone}"/>
<apex:outputfield value="{!a.Active__c}"/>
<apex:outputfield value="{!a.CleanStatus}"/>
</apex:pageblocksection>
</apex:repeat>
-->
<apex:pageblockTable value="{!accs}" var="a">
<apex:column value="{!a.Name}"/>
<apex:column value="{!a.Phone}"/>
<apex:column value="{!a.Active__c}"/>
<apex:column value="{!a.CleanStatus}"/>

</apex:pageblockTable>

</apex:pageblock>


</apex:page>

apex class:

public class accountInformation {


public list<Account> accs{ get; set;}

public list<Account> getAccounts(){

accs=[select Name,Phone,Active__c,CleanStatus from Account];
system.debug('Account info:'+accs);
return accs;
}

}