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  

"Can Grow" property



 
 
Thread Tools Display Modes
  #1  
Old January 2nd, 2006, 03:01 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default "Can Grow" property

I have 3 fields in a report with the "Can Grow" property set to true. In
most cases only one cell (comments) is the one that grows in size vertically.
I've used borders around the fields to create an appearance of a table cell
for each item. Yet, when only one grows, all their border lines don't grow
together. Is there a way to make all the fields grow to the same height at
once?
--
Thanks!
Mona-ABE
  #2  
Old January 2nd, 2006, 03:16 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default "Can Grow" property

Mona-ABE wrote:
I have 3 fields in a report with the "Can Grow" property set to true.
In most cases only one cell (comments) is the one that grows in size
vertically. I've used borders around the fields to create an
appearance of a table cell for each item. Yet, when only one grows,
all their border lines don't grow together. Is there a way to make
all the fields grow to the same height at once?


It's not trivial to do. Basically you remove the visible borders from your
TextBoxes and then draw your own using the following methods. This assumes a
detail section with TextBoxes that start at the very top of the section and
extend to the botttom of the section.

Use the line tool from the Toolbax to draw two horizontal lines, one above the
row of TextBoxes and one just below. Test the report to ensure that the lower
horizontal line is properly "pushed" down the page when TextBoxes grow.

Now you use code in the detail section's OnFormat event to draw the vertical
lines using the line method of the report. The line method basically allows you
to draw lines and boxes by specifying the upper left coordinate and the lower
right coordinate. Here you take advantage of one behavior of the line method.
That is that you cannot use the line method to draw a line or box that extends
outside of the section where the method is called. In this case since we are
using the line method in the format event of the Detail section then no matter
what coordinates you use the lines created cannot extend above or below the
detail section.

Given the above all you have to do is specify 0 as the top coordinate and a very
large number for the lower coordinate and the lines thus drawn will always
extend to the bottom of the detail section as it grows and shrinks.

Using the line method requires a bit of trial and error to get the positioning
correct, but once you have one line drawn all you have to do is copy that line
of code and change the coordinates that control the horizontal position for the
next line you want.

--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com







  #3  
Old January 2nd, 2006, 03:21 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default "Can Grow" property

The general solution is to NOT display the borders. Use code in the On Print
event of the report section to draw lines using the Line method. Stephen
Lebans has some sample code at http://www.lebans.com/PrintLines.htm.

--
Duane Hookom
MS Access MVP
--

"Mona-ABE" wrote in message
...
I have 3 fields in a report with the "Can Grow" property set to true. In
most cases only one cell (comments) is the one that grows in size
vertically.
I've used borders around the fields to create an appearance of a table
cell
for each item. Yet, when only one grows, all their border lines don't
grow
together. Is there a way to make all the fields grow to the same height
at
once?
--
Thanks!
Mona-ABE



 




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
Using the HasContinued property Steve Kerry Setting Up & Running Reports 1 February 28th, 2005 08:35 AM
Help with assigning variable names ad General Discussion 13 October 8th, 2004 12:15 AM
How do I shorten the length of property values? bvlevere Using Forms 1 September 22nd, 2004 05:46 PM
Q2: KeepTogether property in Report Design View Jeff Conrad General Discussion 3 August 11th, 2004 07:35 AM
RTF2 Property is read-only RobGriff85 General Discussion 6 August 6th, 2004 05:17 AM


All times are GMT +1. The time now is 10:52 PM.


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