[AccessD] Conditional keep together

Boyd Trimmell accesscoach at hitechcoach.com
Thu Jan 20 13:03:09 CST 2011


If the section that is set to group together is skipping to the next page
that mean that it will not fit on the page with the other sections.  

II probably is a combination of the Report Header and any other headers
together being too  tall. What this does is not leave  enough room to keep
the records together on the same page.  

AFAIK, one a report starts calculating what will fit on a page you can't
change the keep together setting.  If you were to be able to change this
property for keep together on the fly while the report is generating this
would really make the pagination very difficult to generate. Besides it
would be very, very, slow.  

Note: I rarely set the  Keep Together property  to yes.  This is usually the
first thing I set to No  when trying to fix issues with other people's
reports.   

I do use the force new page property for grouping  sections  to keep groups
of records together on separate pages.

Boyd Trimmell 
aka HiTechCoach at UtterAccess.com and other support sites
Microsoft Access MVP 2010 ( MVP Profile )



-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Debbie
Sent: Thursday, January 20, 2011 10:40 AM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] Conditional keep together

I started to put a conditional keep together in code on format. This
actually crashes Access. Only in the on open event will it work.

I have started experimenting with adding a conditional page break. I can get
it to work only when I want, but the records still start on page 2. I just
get a page break in the middle of page 2 rather than moving the first part
of the records to page 1

Debbie

Sent from my iPhone

On Jan 20, 2011, at 9:21 AM, "Rocky Smolin" <rockysmolin at bchacc.com>
wrote:

> Is it a function of how many records there are in the group?  I 
> wouldn't want to hard code a test for a specific data value if I could 
> avoid it.
>
> You can, of course, set the keep together property through code, but 
> the question is where to do it?
>
> I've never tried this but I'd experiment with the Format event of the 
> group header.
>
> Rocky
>
>
> -----Original Message-----
> From: accessd-bounces at databaseadvisors.com
> [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Debbie
> Sent: Thursday, January 20, 2011 6:48 AM
> To: Access Developers discussion and problem solving
> Subject: [AccessD] Conditional keep together
>
> I have a report with 2 grouping levels. The first group is keep 
> together with first record and the second is keep all records together 
> on one page.
> 99.9% of the time this is perfect.
>
> Now I have the situation where my first keep all records together 
> group fits perfectly on a page all by itself. This means I have a 
> report header, further group header, then a page break. Not until page
> 2 do I see this first set of detail records because if the keep 
> together.
>
> I do not want to set this to keep with first record just to cover this 
> one instance with one user, but I have to admit it is pretty awful. Is 
> there any way to determine that this has happened ahead of time and 
> reset the keep together property?  Better yet only reset it on the 
> group having problems.
>
> I can set the keep together, but only on open. By the time I can tell 
> if it is needed, my window of opportunity is lost and I am better off 
> just setting this group to keep together with first record and just be 
> dine with it.
>
> Debbie
>
> Sent from my iPhone
> --
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
>
> --
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
>
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com




More information about the AccessD mailing list