You need to sign in to do that
Don't have an account?
Showing records in VF based on a field value
Hi all,
I have made a start with a visual force page to show specific records based on a field value. I've got the next code that displays all the records (but hides them when the value of field is other then "Opgelost"). What i want to achieve is that only the records with the value "Opgelost" in the field are shown.
Which bit of code should i add ?
<apex:page standardController="Storing__c" recordSetVar="Storingen">
<apex:repeat value="{!storingen}" var="c">
<apex:pageblock >
<apex:outputText value="{!c.Id}" rendered="{!c.Status__c =='Opgelost'}" />
<br/>
<apex:outputText value="{!c.Soort_storing__c}" rendered="{!c.Status__c =='Opgelost'}" style="font-weight:bold" />
<br/>
<apex:outputText value="{!c.Status__c}" rendered="{!c.Status__c =='Opgelost'}" style="font-weight:bold" />
<br/>
<apex:outputText value="{!c.Systeem__c}" rendered="{!c.Status__c =='Opgelost'}" style="font-weight:bold" />
<br/>
<apex:outputText value="{!c.Voor_welke_klanten_geldt_dit__c}" rendered="{!c.Status__c =='Opgelost'}" style="font-weight:bold" />
<br/>
<apex:outputText value="{!c.Wat_is_het_probleem__c}" rendered="{!c.Status__c =='Opgelost'}" style="font-weight:bold" />
<br/>
</apex:pageblock>
</apex:repeat>
</apex:page>
I have made a start with a visual force page to show specific records based on a field value. I've got the next code that displays all the records (but hides them when the value of field is other then "Opgelost"). What i want to achieve is that only the records with the value "Opgelost" in the field are shown.
Which bit of code should i add ?
<apex:page standardController="Storing__c" recordSetVar="Storingen">
<apex:repeat value="{!storingen}" var="c">
<apex:pageblock >
<apex:outputText value="{!c.Id}" rendered="{!c.Status__c =='Opgelost'}" />
<br/>
<apex:outputText value="{!c.Soort_storing__c}" rendered="{!c.Status__c =='Opgelost'}" style="font-weight:bold" />
<br/>
<apex:outputText value="{!c.Status__c}" rendered="{!c.Status__c =='Opgelost'}" style="font-weight:bold" />
<br/>
<apex:outputText value="{!c.Systeem__c}" rendered="{!c.Status__c =='Opgelost'}" style="font-weight:bold" />
<br/>
<apex:outputText value="{!c.Voor_welke_klanten_geldt_dit__c}" rendered="{!c.Status__c =='Opgelost'}" style="font-weight:bold" />
<br/>
<apex:outputText value="{!c.Wat_is_het_probleem__c}" rendered="{!c.Status__c =='Opgelost'}" style="font-weight:bold" />
<br/>
</apex:pageblock>
</apex:repeat>
</apex:page>
Please modify your page code as below :
Let me know if you have any issue in this.
Thanks,
Abhishek
All Answers
Please modify your page code as below :
Let me know if you have any issue in this.
Thanks,
Abhishek
Thanx a lot Abhishek
Regards,
Abhishek