You need to sign in to do that
Don't have an account?

how to display records on visualforce page using dynamic query ?
query = 'Select ' + CorrespondingFields + ' from ' + AllObjectsList;
Here, object and fields of that object both are dynamic.
pls help how to display records in table on visualforce page.
Here, object and fields of that object both are dynamic.
pls help how to display records in table on visualforce page.
You can use below page and controller as a reference.
Page:
Controller:
Let me know if this helps you.
All Answers
Basically you need to
1) prepare query string
2) execute that query using database.query(dynamicQuery)
3) use returned records in vf page like in pageblock table for showing in tabular format.
i have done these step alerady like
query = 'Select ' + CorrespondingFields + ' from ' + AllObjectsList;
list<sObject> slist = database.query(query);
but only problem is that i am not able to display it on the vf page, dont know what should i write on value tags to display records as the object and fields are dynamic
<apex:PageBlockTable value=" " var="dynamicfields">
<apex:column value=" " />
</apex:PageBlockTable>
You can use below page and controller as a reference.
Page:
Controller:
Let me know if this helps you.