I have a requirement to display the custom object records as a Dynamic Tab in a VF Page. I am able to create the static Tabs but I am not able to create the Tabs dynamically based on the Custom Object Records.
For example, I have a custom object called Product Initiative. In the Product Initiative object we have 4 records like product1, Product2...and Product4. In the VF page I need to display this 4 records as a Tab. If the user creates one more record in Product Initiative then the 5th Tab has to be added dynamically. Hope the requirement is clear to all. Please find below the image for more clarification. Can anyone please help me out in the requirement? enter image description here

3 Answers 3


You can use Jquery tabs for this. http://jqueryui.com/tabs/

You can collect all the records in a list by SOQL query and then using repeat tag you can use jquery tabs to display then as tabs.

  • thanks for your reply i already tried this method but i can't display a tab format.
    – Udaya
    Commented Jan 20, 2014 at 11:41
  • I used this as well to get around lack of support for apex:repeat. Always amazing some of the stuff they make a pain to work with.
    – Adrian Larson
    Commented May 19, 2015 at 14:21

you can use this awesome package which uses jquery behind the scene -


Demo Link - http://blogforce9dev-developer-edition.ap1.force.com/jQueryTabDemo


This was solved in a discussion on the developer forum. This is the current link - https://developer.salesforce.com/forums/ForumsMain?id=906F000000094jfIAA - read all the way to the bottom for the full solution.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .