Column Lines

J

Janis in Minnesota

HELP! :)
I am having a problem putting vertical lines that go from a header through
all detail, and in the detail section there are 6 subreports that can grow
and shrink. The lines need to go thru all detail and subreports to the
footer and the lines are constant - they are always the length of the invoice
report. Will I need to use Crystal Reporting to do this easily? I am
having one heck of a time with these lines and it seems something that sounds
so simple is causing me to have rapid gray-hair growth! ha!

Thanks much for any information,

Janis
 
M

Marshall Barton

Janis said:
I am having a problem putting vertical lines that go from a header through
all detail, and in the detail section there are 6 subreports that can grow
and shrink. The lines need to go thru all detail and subreports to the
footer and the lines are constant - they are always the length of the invoice
report.


Not sure of exactly what you want when you say a line "from
a header".

You can use the report's Page event to draw a line anywhere
on the page using the Line method. E.g.

Me.Line (5*1440,720) - Step(0, 14400)

will draw a line5 inches from the left and 1/2 inch from the
top of the page down to 10 inches from the top.
 
D

Duane Hookom

It has been suggested before to use the Line Method in the On Page event of
your report. I just tested this and the line drawn with code is clearly
visible "through" the subreport.

What is wrong with code like this?

Private Sub Report_Page()
Me.DrawWidth = 10
Me.ForeColor = vbRed
Me.Line (1440, 1000)-Step(0, 20000)
End Sub
 
J

Janis in Minnesota

need mulitple column lines that extends from the top of the report thru the
detail to the bottom of the report - a vertical line. I have multiple sub
reports within the detail and it seems I will have to add lines in there as
well, figure out where to place the lines, allow them to grow or shrink with
the report. I'm thinking I may need to go with Crystal reports as I'm about
at my wits end. We print on paper that already has column lines preprinted
but would like to send the reports to a laser printer and just print the
column lines as well as the data.
The data would be something like Product | Cost | Ext Cost | where the
lines would go all the way through the report no matter if there are
subreports in there or not. I have tried working with the me.line (5* . . .
to no avail so obviously I am doing something wrong. :( I wish you could
draw a line that starts from the header and drag it down to the footer and
whatever is between line continues through. Is this possible without
writing a lot of code to do this? Sounds like I will have to write code in
each subreport as well.
Thanks!

Janis
 
J

Janis in Minnesota

I have been putting the line in the header and the code on the On Format
property. Thank you very much for pointing out my stupidity. :)

Janis
 
J

Janis in Minnesota

OK I GOT IT!!!!! DUH!!! Ok the ON page property of the REPORT is where the
code goes, and you can put as many lines as you need in there without
creating a line in the header, detail, and subreports. You create them in
the on page property of the Report. Thanks so much everyone! Yes it took
me a little to get this one. Sheesh. Sorry!

Janis
 
M

Marshall Barton

Sometimes we read one thing and think something else.

Sometime we write something when we're thinking another
thing --- You do NOT put code in the OnPage property, you
put it in the Page Event **Procedure** <Grin>

Glad you got it doing what you want
 
Top