I am building a custom visualforce page to display list of Accounts and wanted to take advantage of the custom Account Controller filter Property to be able to filter accounts on the page. All I get is just 1 value on the ListView e.g 'All', I want to be able to see e.g 'Recently Viewed Accounts','New This Week' etc. I have checked my code but can't find any error. My code is below.I will be glad if someone can help.
<apex:page standardController="Account" recordSetVar="accounts">
<apex:form >
<apex:pageBlock title="Account List" >
<apex:outputLabel value="View:"/>
<apex:selectList value="{!filterId}" size="1">
<apex:selectOptions value="{!listviewoptions}"/>
</apex:selectList>
<apex:pageBlockTable value="{!accounts}" var="a">
<apex:column > <!-- apex:colum is used to provide columns for pageBlockTables -->
<apex:facet name="header"> <!-- apex:facet is used to provide header and footer names for the columns in the pageBlockTables -->
Account Name
</apex:facet>
<apex:facet name="footer">
End of Table
</apex:facet>
<apex:outputField value="{!a.Name}"/>
</apex:column>
<apex:column >
<apex:facet name="header">
Account Phone Number
</apex:facet>
<apex:outputField value="{!a.Phone}"/>
</apex:column>
</apex:pageBlockTable>
<apex:commandLink action="{!previous}">Previous</apex:commandLink> <!-- this is used to add the previous page button to the page-->
<apex:commandLink action="{!next}"> Next</apex:commandLink> <!-- this is used to add next page button to the page-->
</apex:pageBlock>
</apex:form>
Recently Viewed Accounts
.... check my attached image..