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

How to display all submitted records for an approval process along with their status in VF Page
Hi,
I have a requirement to list all approval process in Visualforce Page in picklist and when user select any approval process, the system should display all the records which are submitted for approval along with their status.
Thanks in advance
suresh.
I have a requirement to list all approval process in Visualforce Page in picklist and when user select any approval process, the system should display all the records which are submitted for approval along with their status.
Thanks in advance
suresh.
If it got matched, then process Instance record will be stored in a list and will be displayed to the user.
Visualforce page snapshot:
Notes:
First create remote site setting with Remote Site URL as https://xxx.salesforce.com where xxx domain name like ap1,na1 etc.
I tried to filter the number of processInstance records by putting where clause but it didn't work for me. So I queried all processInstance records.
We can specify where clause on created date or last modified date by giving an option to the user to select a date range. We can display two more fields as start date and end date on VF page and system will display only process instance records created or modified between these 2 dates.
Below is Visualforce page code: Apex Class Code:
kindly mark it as solved if it helps you.
Best Regards,
Rakesh Thota.
All Answers
If it got matched, then process Instance record will be stored in a list and will be displayed to the user.
Visualforce page snapshot:
Notes:
First create remote site setting with Remote Site URL as https://xxx.salesforce.com where xxx domain name like ap1,na1 etc.
I tried to filter the number of processInstance records by putting where clause but it didn't work for me. So I queried all processInstance records.
We can specify where clause on created date or last modified date by giving an option to the user to select a date range. We can display two more fields as start date and end date on VF page and system will display only process instance records created or modified between these 2 dates.
Below is Visualforce page code: Apex Class Code:
kindly mark it as solved if it helps you.
Best Regards,
Rakesh Thota.
Hi Suresh,
You can also achieve this with report & report type.
Create a new report type with "Process instance" as main object & "Process Instance Node" as child object.

Then create a report using this report type. It will look somthing like,