Jump to content

This topic is 6905 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

When in list view, with say 100 found records, IWP shows the records in blocks of 25. So....

1) Is there a way to navigate to the next page of 25 records when the status area is hidden, in other words buttons on the page.

2) Is there a way to show that the user is looking at records 1-25 of 100 found records, again with the status area hidden.

I know its possible to show all the records if i use a portal, but wanted an easier way to sort/find records

Posted (edited)

Hi Mikeytt

For your first question, the way I have done this is to setup a calculation that uses the script step 'Go to Record/Request/Page' using the option of 'By Calculation...'

And the calculation for this is:

Get ( RecordNumber ) + 25


Or you can setup a script that does the same thing.



And for your second question, I have not done this in IWP yet but the way I would do this is to create a global to set the page information at the end of the script. After script step above, the next step of your script should be a 'Set Field' with the global as the target field and the calculation for this to be:




Get ( RecordNumber ) // Current record number



& "-" & 



/* This next bit works out if the last

record on screen is the last record or

not, and sets the number appropriately */



If ( 

    ( Get ( RecordNumber ) + 25 ) > Get ( FoundCount ) ; 

    Get ( FoundCount ) ; 

    Get ( RecordNumber ) + 25 ) & 



" of " & 



Get ( FoundCount ) // Total records

I hope this makes sense and is what you are looking for.

Regards

Orlando

Edited by Guest
Posted

Hi - the first part works great and i have used this to fulfill the second part as well, a bit differently to how you have suggested,, as I wanted it to be "live" so it is also done by calculations.

So now at the top of the page it says

showing records X to Y of total of Z

x= Get ( RecordNumber )

Y= If((current_rec + 24)>found_recs;found_recs;current_rec + 24)

Z=Get ( FoundCount )

This also allows me to put in two buttons, one which says

show records A to B (to move to the previous 25) and another which says show records C to D (to ove to the next 25 or part thereof).

A=If((X-25)<1;1;X-25)

B=If((A+24)>Z;Z;A+24)

C=If((X+25)>Z;Z;X+25)

D=If((C+24)>Z;Z;C+24)

Thanks for your help, i was a bit stuck and it helped.

This topic is 6905 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.