Export excel using pzRDExportWrapper is giving incorrect results
User have a requirement where he should export the data of RD on screen to excel file. In order to achieve this, user embedded a button. From there user call the OOTB activity "pzRDExportWrapper".
User is passing clipboard's RD page for step page as this is the OOTB place that PRPC creates when it runs RD. However, it is not behaving correctly, as it is not giving filtered results from UI.
Steps to Reproduce
1. Display a repeating grid which gets sourced from Report Definition.
2. Apply a filter by passing a filter value to RD to filter the results in UI.
3. Embed a button in UI to call pzRDExportWrapper OOTB activity to export the results.
4. Downloaded excel will have all the results from RD.
The root cause for this behaviour is stated below -
1. The Grids does not support Export to Excel feature until now .
2. There is a story created in the backlog which will be implemented in the near future (US-34553)
3. The activity pzRDExportWrapper is only for Reporting needs It may not be useful for the users to use it in Achieving Export to Excel functionality in Grids.
This issue is resolved through the following local change to apply the filters in excel results from UI.
1. The OOTB activity runs on the clipboard's RD page context and any filters applied on UI grids level will not considered as per the root cause notes.
2. As we know, OOTB activity is for exporting the results from RD and any filters applied at RD level will only be applied and so we have to pass the filter value for the filter property which is available at RD (Param.workStatus).
3. The passed filtered value will get set to workStatus at activity level and OOTB activity runs on clipboard's RD page context where the filter workStatus will be resolved and applied to get the filtered results.
To implement this, we can follow the simple steps -
1. Add a parameter at OOTB calling activity and pass a filter value from UI on click action set.
2. Before calling the OOTB activity on step2, add property-set at step 1 and alter the step 2 to pass current page parameter page as shown below.
The parameter on the activity should be same filter applied at RD level.
This procedure helped the user to get the filtered results from UI on to excel.
Published May 12, 2015 - Updated October 8, 2020
Was this useful?
0% found this useful
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.