A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

extending inner border lines for report that displays an invoice



 
 
Thread Tools Display Modes
  #1  
Old March 8th, 2006, 09:41 AM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default extending inner border lines for report that displays an invoice

Hello,

I've got a real annoying problem at the minute, I have a subreport within a
report. the subreport displays the individual lines within the invoice. A
line for example would be 1 |* |Book |@ £10| . each field is seperated by a
"line", demonstrated here using the pipe | . There could be any number of
"invoice lines" within an invoice.

What we are aiming for is that the subreport which contains the "invoice
lines" to stay the same height, no matter how many invoices lines are used,
which we can achieve by expanding the supreport to the desired height and
setting "Can Shrink" to No, around the subreport we have placed a border so
as it looks a bit like a squa
_________________
| qty | product | price |
----------------------

however the internal "lines",which separate the fields are only every as
tall as the amount of "invoice lines" that are displayed. We are trying
desperately to display the internal "lines" with the same height as the
subreport no matter how many invoice lines there are such as this
_________________
| qty | product | price |
| 1 | book | 10 |
| | | |
| | | |
----------------------

At the moment we are only getting something like this, which looks awful!

_________________
| qty | product | price |
| 1 | book | 10 |
| |
| |
----------------------

I hope that makes sense and that the diagrams above are being displayed
correctly, and someone can help with this issue!!!!

All the best

Graham


  #2  
Old March 8th, 2006, 03:38 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default extending inner border lines for report that displays an invoice

a wrote:
I've got a real annoying problem at the minute, I have a subreport within a
report. the subreport displays the individual lines within the invoice. A
line for example would be 1 |* |Book |@ £10| . each field is seperated by a
"line", demonstrated here using the pipe | . There could be any number of
"invoice lines" within an invoice.

What we are aiming for is that the subreport which contains the "invoice
lines" to stay the same height, no matter how many invoices lines are used,
which we can achieve by expanding the supreport to the desired height and
setting "Can Shrink" to No, around the subreport we have placed a border so
as it looks a bit like a squa
_________________
| qty | product | price |
----------------------

however the internal "lines",which separate the fields are only every as
tall as the amount of "invoice lines" that are displayed. We are trying
desperately to display the internal "lines" with the same height as the
subreport no matter how many invoice lines there are such as this
_________________
| qty | product | price |
| 1 | book | 10 |
| | | |
| | | |
----------------------

At the moment we are only getting something like this, which looks awful!

_________________
| qty | product | price |
| 1 | book | 10 |
| |
| |
----------------------



This kind of thing is not just annoying, it's downright
complicated. In a main report, this kind of thing is best
dealt with by using the Line method in the Page event.
Unfortunately, subreports don't recognize the Page event so
that won't work. I think there might be a way since you do
not allow the subreport to span a page boundary.

First, add an invisible text box named txtTotLines to the
subreport's Report Header section and set its ControlSource
expression to =Count(*)

Next add an invisible text box named txtCntLines to the
detail section. Set its ControlSource expression to =1 and
RunningSum property to OverAll.

Now add code to the Detail section's Format event procedure
so that it looks something like this air code:

Static intBlanks As Integer
Select Case intBlanks
Case 0
If txtCntLines = txtTotLines Then
intBlanks = 1 'Last detail
Me.NextRecord = False
End If
Case 1 'First blank line
intBlanks = intBlanks + 1
Me.txtQty.Visible = False
Me.txtproduct .Visible = False
Me.txtprice.Visible = False
Me.NextRecord = False
Case 12 'other blank lines
intBlanks = intBlanks + 1
Me.NextRecord = False
End Select

where the 12 is the number of blank lines that would be
needed if there were only one detail.

--
Marsh
MVP [MS Access]
  #3  
Old March 9th, 2006, 02:27 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default extending inner border lines for report that displays an invoice

Hello,

Thanks for that i am now giving that a try

Cheers

"Marshall Barton" wrote in message
...
a wrote:
I've got a real annoying problem at the minute, I have a subreport within
a
report. the subreport displays the individual lines within the invoice. A
line for example would be 1 |* |Book |@ £10| . each field is seperated by
a
"line", demonstrated here using the pipe | . There could be any number of
"invoice lines" within an invoice.

What we are aiming for is that the subreport which contains the "invoice
lines" to stay the same height, no matter how many invoices lines are
used,
which we can achieve by expanding the supreport to the desired height and
setting "Can Shrink" to No, around the subreport we have placed a border
so
as it looks a bit like a squa
_________________
| qty | product | price |
----------------------

however the internal "lines",which separate the fields are only every as
tall as the amount of "invoice lines" that are displayed. We are trying
desperately to display the internal "lines" with the same height as the
subreport no matter how many invoice lines there are such as this
_________________
| qty | product | price |
| 1 | book | 10 |
| | | |
| | | |
----------------------

At the moment we are only getting something like this, which looks awful!

_________________
| qty | product | price |
| 1 | book | 10 |
| |
| |
----------------------



This kind of thing is not just annoying, it's downright
complicated. In a main report, this kind of thing is best
dealt with by using the Line method in the Page event.
Unfortunately, subreports don't recognize the Page event so
that won't work. I think there might be a way since you do
not allow the subreport to span a page boundary.

First, add an invisible text box named txtTotLines to the
subreport's Report Header section and set its ControlSource
expression to =Count(*)

Next add an invisible text box named txtCntLines to the
detail section. Set its ControlSource expression to =1 and
RunningSum property to OverAll.

Now add code to the Detail section's Format event procedure
so that it looks something like this air code:

Static intBlanks As Integer
Select Case intBlanks
Case 0
If txtCntLines = txtTotLines Then
intBlanks = 1 'Last detail
Me.NextRecord = False
End If
Case 1 'First blank line
intBlanks = intBlanks + 1
Me.txtQty.Visible = False
Me.txtproduct .Visible = False
Me.txtprice.Visible = False
Me.NextRecord = False
Case 12 'other blank lines
intBlanks = intBlanks + 1
Me.NextRecord = False
End Select

where the 12 is the number of blank lines that would be
needed if there were only one detail.

--
Marsh
MVP [MS Access]



 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Border lines not printing bsuiter Worksheet Functions 0 May 26th, 2005 01:36 PM
Add lines to invoice template yancy Worksheet Functions 0 February 1st, 2005 12:39 AM
Lines on Chart border (bug!?) routeram General Discussion 1 September 22nd, 2004 02:24 AM
Add free text lines to an invoice form Peter De Tender Using Forms 3 September 10th, 2004 08:57 AM
Lines appear in my Word docs, like the horizontal border of a box. adam General Discussion 1 September 10th, 2004 12:49 AM


All times are GMT +1. The time now is 10:47 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.