Ok I took that code out and the pop up no longer comes up. However still not counting correctly for some reason. I am missing something for some reason...Just not sure what it is.
May or may not be at work tomorrow, big icestorm heading our way.
Thanks again mate much appreciated. Your a huge help. Owe yeah a beer lol
![]()
Why would it start from page 2?
Anyway, if you want that, just change the initial value of NoOfPages in InitToc() function to 1 (it's 0 now).
I mean that 3rd case under Decisions Released in actually on the 2nd page. First two cases are on pg 1 so that is fine.
Oh, ok, I'll have a look at it tomorrow. In db you sent last time all reports had one page only.
Ok, this one counts properly. I changed the code a bit again so make sure you got the most actual one.
Testing_Litigation_DB1.zip
Thanks I will take a look![]()
How many cases is on that first report? Four. And I can see three only on your ToC report. Second report also contains 4 cases, and again I can see three.
Did you remember that you HAVE TO cycle through all pages of every report in order to make entry in ToC table? It won't enter all cases automatically just by opening print preview. You must print preview EVERY page, that's where "magic" happens.
Exactly same db shows this, when previewed correctly:
![]()
Unfortunately I had a db crash and lost a few days work..Will test it when I get it all back..Makes sense though that I need to cycle through.
Thanks
Got it all up and running. Thanks for all your help!!!
Much appreciated have a great weekend.
Pete
Hey just printing things out creating title pages and stuff.. I wonder if there is a way to get access to print the correct pages numbers on the reports themselves. Didn't think to check that.
Ie I print 3 reports as you know and each report has page numbers on the bottom but they start over for each page. So the Table of Contents is correct but the page numbers are not.
Think that is possible to pull the data from that?
Wouldn't be easier to just print one report containing all 3 as subreports? Much less mess with page numbers and ToC updating. Especially if you're always going to print all 3.
Ok will look up how to do that and give it a go![]()