Problem navigating picture gallery (1 Viewer)

Dreamweaver

Well-known member
Local time
Today, 21:36
Joined
Nov 28, 2005
Messages
2,466
Hi Hope somebody will be abe to help me with this.

I'm currently building a picture gallery example but have found a problem with the page navigation It relates to when you open the screen then select an entity and gallery for entity all works fine but if you click the go to last button the page thats displayed is not the last one but the last full page please see image.

If I use the go to next before clicking the go to last all works fine I have a counter that keeps track of where I am which works just fine except for the above:banghead:

Please NOTE if you don't like the colours go to preferences and change them lol

This is a work in progress but it works as is the delete works but I need to add code to it to move all below deleted placement but thats not a problem

I have used a place holder so images can be move to how the user wishes all that sort of thing will be added

Thanks for looking at it should you make edits please sign them As I wont take credit for other work.

I have left images in it so have added it to my site here:
https://databasedreams.createaforum.com/picture-gallery/download-picture-library-example/
thanks mick

You will need to update the image folder loaction in preferences

This is the second page which should be the 3rd as below this image



This is what should be displayed
 

Attachments

  • 2019-09-25.jpg
    2019-09-25.jpg
    108.6 KB · Views: 166
  • 2019-09-25 (1).jpg
    2019-09-25 (1).jpg
    99.7 KB · Views: 178
Last edited:

June7

AWF VIP
Local time
Today, 13:36
Joined
Mar 9, 2014
Messages
5,423
Mick has 52 images in Programs gallery. Which means last page should display 12 images yet it only displays 11. So seems to be more wrong with algorithm than just not going to last page from first.

I had a similar requirement and solution involved a temp table bound to report described at https://www.accessforums.net/showthread.php?t=21972. Sure it could be adapted to form. Load data to temp table and then user could just scroll records on form.
 
Last edited:

Dreamweaver

Well-known member
Local time
Today, 21:36
Joined
Nov 28, 2005
Messages
2,466
Mick has 52 images in Programs gallery. Which means last page should display 12 images yet it only displays 11. So seems to be more wrong with algorithm than just not going to last page from first.

I had a similar requirement and solution involved a temp table bound to report described at https://www.accessforums.net/showthread.php?t=21972. Sure it could be adapted to form. Load data to temp table and then user could just scroll records on form.


Hi June7 I deleted one or missed it but will look at it just in case thanks for looking
 

Dreamweaver

Well-known member
Local time
Today, 21:36
Joined
Nov 28, 2005
Messages
2,466
You Are correct it is losing one image I just created a new gallery and added and was very careful to add them all 53 in the end but seem to lose one so will need to look into that but it could be the exist checker thanks will check after work
 

Dreamweaver

Well-known member
Local time
Today, 21:36
Joined
Nov 28, 2005
Messages
2,466
Found the problem with the counter when gallery first selected placement =0 then on second page placement is placement+21 which is ok up to 2 pages but on 3rd page placement will be 21 and I add another 21 which makes the starting point = 42 when it should be 41.

So what I need do is something like (placement +1)+20 which should correct that problem I may have to check that the value doesn't drop below 0 on navigating back to first page but that's an easy fix if I'm not worrying over nothing lol
Edit the above wont work same problem different method but think I have it all sorted at least in my head lol
And I think my main problem with going to last pages is just a math problem which I think I have a solution for but will have to wait till home to try that out lol
 
Last edited:

Dreamweaver

Well-known member
Local time
Today, 21:36
Joined
Nov 28, 2005
Messages
2,466
I've removed this file but will add it to the sample databases soon as I have the first version complete
 

Users who are viewing this thread

Top Bottom