Showing posts with label kept. Show all posts
Showing posts with label kept. Show all posts

Wednesday, March 7, 2012

Keeping Multiple Detail Lines in a Table Together

I have a table in my report. The table has two detail lines per detail item. My problem is that the two lines really need to be kept together, and the table will page break between the lines when the end of page is reached. I have been looking through the different table properties, and I have not been able to locate anything that lends a hand to my issue. I did some quick searches, and I couldn't find another thread requesting this information. I may just be missing something obvious.

Any help and/or advice would be great! Thanks.

Curtis

P.S.

This is what I am working with

Detail 1 = Product Description, Product Number

Detail 2 = Various Pricing and Units of Measure, Barcode

It makes it a little difficult if these two lines are not kept together! Thanks again!

I have not come up with a solution for my "Keeping Multiple Detail Lines in a Table Together", but I have thought up a work around that I would like to use. I wanted to page break at a specified line number to reduce or eliminate the detail lines being separated, because of where they fall on the page. The problem is, I cannot get the work around to function.


Page Breaks
In some reports, you may want to place a page break at the end of a specified number of rows instead of, or in addition to, on groups or report items. To do this, create a group in a data region (typically a group immediately outside the detail), add a page break to the group, and then add a group expression to group by a specified number of rows.

The following expression, when placed in the group expression, assigns a number to each set of 25 rows. When a page break is defined for the group, this results in a page break every 25 rows.

=Int((RowNumber(Nothing)-1)/25)


The preceding information was located in a help file that I found. (ms-help://MS.VSCC.v80/MS.MSDN.v80/MS.SQL.v2005.en/rptsrvr9/html/87ddb651-a1d0-4a42-8ea9-04dea3f6afa4.htm to reference the help file) I created a group immediately outside my details. In the expression for the group I inserted the code verbatim.

I clicked preview, and the page break broke the report. I received the following error:

[rsInvalidGroupExpressionScope] A group expression for the table ‘table1’ uses the RowNumber function with a scope parameter that is not valid. When used in a group expression, the value of the scope parameter of RowNumber must equal the name of the group directly containing the current group.

So, what do I insert for "Nothing" that would give me the desired results?

Any help/advice is greatly appreciated!

Thanks

Curtis

|||One way of doing this is to created a rectangle and embed it in your detail line. This means that you have to use text boxes to display your data rather than the table cells, but it does resolve the problem with keeping the lines together.

Keeping Multiple Detail Lines in a Table Together

I have a table in my report. The table has two detail lines per detail item. My problem is that the two lines really need to be kept together, and the table will page break between the lines when the end of page is reached. I have been looking through the different table properties, and I have not been able to locate anything that lends a hand to my issue. I did some quick searches, and I couldn't find another thread requesting this information. I may just be missing something obvious.

Any help and/or advice would be great! Thanks.

Curtis

P.S.

This is what I am working with

Detail 1 = Product Description, Product Number

Detail 2 = Various Pricing and Units of Measure, Barcode

It makes it a little difficult if these two lines are not kept together! Thanks again!

I have not come up with a solution for my "Keeping Multiple Detail Lines in a Table Together", but I have thought up a work around that I would like to use. I wanted to page break at a specified line number to reduce or eliminate the detail lines being separated, because of where they fall on the page. The problem is, I cannot get the work around to function.


Page Breaks
In some reports, you may want to place a page break at the end of a specified number of rows instead of, or in addition to, on groups or report items. To do this, create a group in a data region (typically a group immediately outside the detail), add a page break to the group, and then add a group expression to group by a specified number of rows.

The following expression, when placed in the group expression, assigns a number to each set of 25 rows. When a page break is defined for the group, this results in a page break every 25 rows.

=Int((RowNumber(Nothing)-1)/25)


The preceding information was located in a help file that I found. (ms-help://MS.VSCC.v80/MS.MSDN.v80/MS.SQL.v2005.en/rptsrvr9/html/87ddb651-a1d0-4a42-8ea9-04dea3f6afa4.htm to reference the help file) I created a group immediately outside my details. In the expression for the group I inserted the code verbatim.

I clicked preview, and the page break broke the report. I received the following error:

[rsInvalidGroupExpressionScope] A group expression for the table ‘table1’ uses the RowNumber function with a scope parameter that is not valid. When used in a group expression, the value of the scope parameter of RowNumber must equal the name of the group directly containing the current group.

So, what do I insert for "Nothing" that would give me the desired results?

Any help/advice is greatly appreciated!

Thanks

Curtis

|||One way of doing this is to created a rectangle and embed it in your detail line. This means that you have to use text boxes to display your data rather than the table cells, but it does resolve the problem with keeping the lines together.

Keep together not working as expected in .pdf

I have a report with a table in it, the table's fields are filled with
subreports. I would like the data in the table to be kept together
without additional page breaks. What is happening though is multiple
page breaks when a subreport's data is too long to fit on the rest of
the page.
Any suggestions for keeping the data running continuously? THis works
fine when viewing the report in HTML view, it usually only breaks when
exporting to a .pdf.Hi,
You had any luck solving this issue?
Me too having the same problem :-(
Thanks,
Ranjith
"mlfike" wrote:
> I have a report with a table in it, the table's fields are filled with
> subreports. I would like the data in the table to be kept together
> without additional page breaks. What is happening though is multiple
> page breaks when a subreport's data is too long to fit on the rest of
> the page.
> Any suggestions for keeping the data running continuously? THis works
> fine when viewing the report in HTML view, it usually only breaks when
> exporting to a .pdf.
>|||There is an implicit KeepTogether on subreports that will most likely push
them to another page. I don't know of any workarounds other than avoiding
subreports.
--
Brian Welcker
Group Program Manager
Microsoft SQL Server Reporting Services
This posting is provided "AS IS" with no warranties, and confers no rights.
"Ranjith Prakash" <RanjithPrakash@.discussions.microsoft.com> wrote in
message news:7692FB96-7DF5-4FC0-8B29-34CCAECDF885@.microsoft.com...
> Hi,
> You had any luck solving this issue?
> Me too having the same problem :-(
> Thanks,
> Ranjith
> "mlfike" wrote:
>> I have a report with a table in it, the table's fields are filled with
>> subreports. I would like the data in the table to be kept together
>> without additional page breaks. What is happening though is multiple
>> page breaks when a subreport's data is too long to fit on the rest of
>> the page.
>> Any suggestions for keeping the data running continuously? THis works
>> fine when viewing the report in HTML view, it usually only breaks when
>> exporting to a .pdf.
>>|||How can we achieve this KeepTogether if instead of subreports, there is large
data in one of the rows which doesnt fit into a page ? The scenario is that
we don't want it to push it to the next page with space remaining on the
previous one, instead it should "fit-what is possible" and break the rest
down to the next page.
Thanks,
Satwik.
"Brian Welcker [MSFT]" wrote:
> There is an implicit KeepTogether on subreports that will most likely push
> them to another page. I don't know of any workarounds other than avoiding
> subreports.
> --
> Brian Welcker
> Group Program Manager
> Microsoft SQL Server Reporting Services
> This posting is provided "AS IS" with no warranties, and confers no rights.
> "Ranjith Prakash" <RanjithPrakash@.discussions.microsoft.com> wrote in
> message news:7692FB96-7DF5-4FC0-8B29-34CCAECDF885@.microsoft.com...
> > Hi,
> >
> > You had any luck solving this issue?
> > Me too having the same problem :-(
> >
> > Thanks,
> > Ranjith
> >
> > "mlfike" wrote:
> >
> >> I have a report with a table in it, the table's fields are filled with
> >> subreports. I would like the data in the table to be kept together
> >> without additional page breaks. What is happening though is multiple
> >> page breaks when a subreport's data is too long to fit on the rest of
> >> the page.
> >> Any suggestions for keeping the data running continuously? THis works
> >> fine when viewing the report in HTML view, it usually only breaks when
> >> exporting to a .pdf.
> >>
> >>
>
>|||You would need to merge the subreport contents into the main report.
--
Brian Welcker
Group Program Manager
Microsoft SQL Server Reporting Services
This posting is provided "AS IS" with no warranties, and confers no rights.
"satwik" <satwik@.discussions.microsoft.com> wrote in message
news:3E5608B4-4290-43A0-845A-6B70C25027B9@.microsoft.com...
> How can we achieve this KeepTogether if instead of subreports, there is
> large
> data in one of the rows which doesnt fit into a page ? The scenario is
> that
> we don't want it to push it to the next page with space remaining on the
> previous one, instead it should "fit-what is possible" and break the rest
> down to the next page.
> Thanks,
> Satwik.
> "Brian Welcker [MSFT]" wrote:
>> There is an implicit KeepTogether on subreports that will most likely
>> push
>> them to another page. I don't know of any workarounds other than avoiding
>> subreports.
>> --
>> Brian Welcker
>> Group Program Manager
>> Microsoft SQL Server Reporting Services
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>> "Ranjith Prakash" <RanjithPrakash@.discussions.microsoft.com> wrote in
>> message news:7692FB96-7DF5-4FC0-8B29-34CCAECDF885@.microsoft.com...
>> > Hi,
>> >
>> > You had any luck solving this issue?
>> > Me too having the same problem :-(
>> >
>> > Thanks,
>> > Ranjith
>> >
>> > "mlfike" wrote:
>> >
>> >> I have a report with a table in it, the table's fields are filled with
>> >> subreports. I would like the data in the table to be kept together
>> >> without additional page breaks. What is happening though is multiple
>> >> page breaks when a subreport's data is too long to fit on the rest of
>> >> the page.
>> >> Any suggestions for keeping the data running continuously? THis works
>> >> fine when viewing the report in HTML view, it usually only breaks when
>> >> exporting to a .pdf.
>> >>
>> >>
>>