You need to sign in to do that
Don't have an account?
Force.platform
pageBlock table doesnt showing data
Hello All,
i want to show data on vf in pageBlockTable format. but its not showing.
vf:
<apex:page controller="View_Order_Controller" sidebar="false">
<apex:sectionHeader title="My Order"/>
<apex:pageBlock >
<apex:pageBlockSection >
<apex:pageBlockTable value="{!finalOrder}" var="v">
<apex:column value="{!v.name}" />
<apex:column value="{!v.Contact_Name__c}" />
<apex:column value="{!v.Delivery_Address__c }" />
</apex:pageBlockTable>
</apex:pageBlockSection>
</apex:pageBlock>
</apex:page>
Controller:
public class View_Order_Controller {
Public List<EOrder__C> finalOrder{get; set;}
public pageReference viewOrder()
{
finalOrder=[select id,name,Contact_Name__c,Delivery_Address__c from EOrder__c where Contact_Name__c='fggffh'];
return null;
}
}
Its showing empty table
i want to show data on vf in pageBlockTable format. but its not showing.
vf:
<apex:page controller="View_Order_Controller" sidebar="false">
<apex:sectionHeader title="My Order"/>
<apex:pageBlock >
<apex:pageBlockSection >
<apex:pageBlockTable value="{!finalOrder}" var="v">
<apex:column value="{!v.name}" />
<apex:column value="{!v.Contact_Name__c}" />
<apex:column value="{!v.Delivery_Address__c }" />
</apex:pageBlockTable>
</apex:pageBlockSection>
</apex:pageBlock>
</apex:page>
Controller:
public class View_Order_Controller {
Public List<EOrder__C> finalOrder{get; set;}
public pageReference viewOrder()
{
finalOrder=[select id,name,Contact_Name__c,Delivery_Address__c from EOrder__c where Contact_Name__c='fggffh'];
return null;
}
}
Its showing empty table
Hi Arati Chirame,
you need to add your query list in constructor because when page are load it being refreshed.
Please try this hope it will help you.
VF Page:
Controller:
If you sure you have record with Contact_Name__c='fggffh' then you can exchange query with this.
Mark as a best if it helps you.
Regards,
Suraj
All Answers
use above code snippet and make sure that you have data in your EOrder__c object.
Hi Arati Chirame,
you need to add your query list in constructor because when page are load it being refreshed.
Please try this hope it will help you.
VF Page:
Controller:
If you sure you have record with Contact_Name__c='fggffh' then you can exchange query with this.
Mark as a best if it helps you.
Regards,
Suraj