Discussion

Paging and Single Select!

Hi,

I know PRPC does not support both the paging and Single Select, i have a requirement here at client's place to have both of them. Is there any alternative approach for this?

Many Thanks,

Regards,
Bharat

**Moderation Team has archived post**

This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.

Comments

Keep up to date on this post and subscribe to comments

Pega
May 7, 2010 - 9:31am

Hi,
In 5.5 you can have them both. Unfortunately, this is not supported in earlier versions.

May 7, 2010 - 10:13am

Hi,

I use version 5.5 however i do not use the PRPC's getContent activity. The content page is already built by another utility and i am using the listview embedded with in a section to display the data which is there on the content page. Will Paging still work? Can you please let me know the steps i need to follow inorder to achieve this?

Many Thanks,

Regards,
Bharat

Pega
May 7, 2010 - 11:17am

You can still do it but you need to make your custom activity support paging.
When Paging is enabled, the content Activity receives the following parameters:
PageIndex (Integer): Index of the page that the content Activity must return. It starts at 1. This should be mapped to property pyPageIndex on the Code-Pega-List page which is the page that contains the data.
PageSize (Integer): indicates Page size. Maximum number of rows that the page should contain. This the value set in the Rule form. It should be mapped to property pyPageSize of the Code-Pega-List page.
ReturnTotalCount (Boolean): Used by the engine to return the total number of records in the dataset. This is set to true by List Views the first time the report is executed. It should be mapped to property pyReturnTotalResultCount of the Code-Pega-List page.

The Content Activity must set the following properties on the Code-Pega-List page before returning the data to the ListView:
pxPageCount : number of pages in the Results set.
pxTotalResultCount: number of records in the entire Results Set. It should be set the first time the report is run (based on the value of parameter ReturnTotalCount). If numeric paging mode is on, then set the value to number of pages up to 10 multiplied by maximum number of pages in a page.
pxResultCount: number of records in the current page.

May 10, 2010 - 5:06am

Hi,

I am having another issue now. I set the paging properties as suggested by you. Now the issue is, i am having all the results being retrieved at a single time (say 50) and when i am mentioning it to display only 25 in first page it is displaying all of them and also when i click page index 2 or 3 or so on, i am getting all the results (50) populated in all the pages. Is there any property mapping that i am missing?

Pega
May 10, 2010 - 8:54am

No, those are all the properties needed. Where are you retrieving the data from? Could you post your SQL?

May 10, 2010 - 9:37am

It is a call to the service. I am building the code-pega-list page using an activity. property-set does all this functionality.

Pega
May 10, 2010 - 9:43am

Ok, now I understand the issue. You need to make sure that the service retrives only the data you need to display. In this case 25 rows at a time.

May 10, 2010 - 10:17am

Okay, if i click on the second page index will i need to have a call to service activity again? because i am having the utitliy in the flow before this flow action to get the data displayed on the clipboard page and just using an empty getContent activity to display the data on the screen.

Pega
May 10, 2010 - 10:52am

You don't have to call the service again if the data is already available but you need to copy, in the content Activity, the next next page that needs to be displayed to the content page from the page returned by the service.

May 10, 2010 - 11:01am

i have the page AppAccountList built using the utiltiy and it has all the results within it. I am using the same page in the listview as the ContentPage. So when i display it, it is displaying all the results of that page in a single page and clicking on next page is also displaying the same results.

Pega
May 10, 2010 - 11:02am

Create a new page and copy the data to it from AppAccountList.
Don't copy the entire data. Copy just the rows you need displayed.

Pega
May 10, 2010 - 11:08am

yes, you do.

May 10, 2010 - 11:08am

so, do i need to use a separate Content Page other than the one that i am building in the utility?

May 10, 2010 - 11:57am

i created a page called AppAccountListTest and copied the results from AppAccountList, so this new page now has all the data from the old page and the paging proerpties set however i still see all the results in a single page.

Pega
May 10, 2010 - 1:05pm

Please don't copy all the data. Copy just the data needed for single page.

May 10, 2010 - 3:46pm

Hi,

if i copy say 25 results onto a single page out of say 50 results and when i click on the Index 2 how can i make it copy from 26th record till 50th record.

Ex: i have A page which has 50 records, copy first 25 records from it on to page B (content page of list view) and how can i copy 26th to 50 onto same content page when i click Page Index 2. Also the results may be upto 200.

Please suggest.

Pega
May 10, 2010 - 4:05pm

As I described earlier, the content Activity receives a parameter called PageIndex which stores the pages index the user pointed to.
So the starting index for the next page is:
(page size * (PageIndex -1)) + 1.
So in your exmaple, the page size is 25, the PageIndex is 2, therefore the starting index is: (25 * (2-1)) + 1 = 26

September 9, 2015 - 3:19am

I am fetching data from store procedure call in the list view using custom get content activity.

I tried setting below paging related properties before calling the store procedure to retrun data to the list view :

- pxPageCount

- pxTotalResultCount

- pyPageIndex

But pagination is not getting enabled for me,all the results are getting displayed ina single page and also I can not see the pagination option on the top of the list view.

October 8, 2015 - 9:42am

I am showing data,search result, using Report defination which is in repeat grid.the each row of the report defination has delete and update button.On pressing delete the data status changes to inactive and the delete button should be deactivated.

Similarly on pressing update a new section gets opened to update data and after successful updation the last report defination page should gets displayed with updated result.

On delete button I wrote an activity(click-->Run activity) to change the status and then refresh list(click-->refresh list).but the current report defination page does not get refreshed.

similar is the case for update.the page 1 gets displayed though I stop Page-New in the preactivity when gets back to search page from update page.

pls help.