You need to sign in to do that
Don't have an account?
keshin okawa
Show wrapperClass to visualforce page
Good day everyone,
I have created a wrapper class which is something like this:
The purpose of this wrapper class is to combine the value of a map and a checkbox. At the moment I've tried to view the data of my wrapper and it is working as expected, but my problem is that how will i show the data of my wrapper specifically the map in it to my visual force page(pageblockTable). I've made something like this :
I have created a wrapper class which is something like this:
public class wrapperClass { public Map<String,List<String>> selectedDefinitionList{get;set;} public Boolean isSelect{get;set;} public wrapperClass(Map<String,List<String>> selectedDefinitionList, boolean isSelect ) { this.selectedDefinitionList = selectedDefinitionList; this.isSelect = isSelect; } }
The purpose of this wrapper class is to combine the value of a map and a checkbox. At the moment I've tried to view the data of my wrapper and it is working as expected, but my problem is that how will i show the data of my wrapper specifically the map in it to my visual force page(pageblockTable). I've made something like this :
<apex:pageBlock > <apex:pageBlockTable value="{!AllObjectFieldMap}" var="field" styleClass="table table-striped"> <apex:column value="{!field.selectedDefinitionList}" headerValue="Salesforce Field"/> </apex:pageBlockTable> </apex:pageBlock>But I cannot see those data inside my map. I think I am lacking something. Please help thank you...
MAP is collection of key-value pairs. You need to iterate MAP using its key values. Below link below help understand:
https://developer.salesforce.com/docs/atlas.en-us.pages.meta/pages/pages_dynamic_vf_maps_lists.htm