Link to home
Start Free TrialLog in
Avatar of kmc10314
kmc10314

asked on

Crystal Report Height of Textbox

Is there a way to get the height of a record of detail section in crystal report?
What i'm trying to do is I have two textboxes, one line and other one is actual data (memo type)
While the data can grow as much as it can, the line box does not grow with the data box,
since it has fixed height.

Is there a way to set up the line textbox so that height of line changes according to the memo textbox in that row?
Avatar of Kurt Reinhardt
Kurt Reinhardt
Flag of United States of America image

Draw an actual box around the text box instead of using borders.  Set the property of the box to "Extend to bottom of section when printing". This will ensure the height of the box will match the height of the memo field.

~Kurt
Avatar of kmc10314
kmc10314

ASKER

May be i'm not clear again.
I have not just one textbox with line but bunch of them..
so putting border around textbox wouldn't work
Perhaps if you upload a screenshot it would help.

~Kurt
Avatar of Mike McCracken
I don't follow either.

Is this a verical line?
If so you could just turn on the left or right border?

Can you show a snapshot of you want?

mlmcc
This is what I want.
I want the lines next to the text change dynamically User generated image
Can you us ethe right and left borders?

Is this the full height of the section?
One thing I have done is to insert a section below it and have the line start hwere I want in the section next to the field then extend it through so it ends just in the next section

In your case try inserting another detail or whatever section it is.  If you use th enext section type the line will extend to the end of the report

mlmcc
OK. the lines there are textboxes with no text, but left border
Do you see how there is two Ds and they are different in size?
The memo (where it says "My Text Goes Here. This HeightVaries") can be one line or 10 lines.
It varies according to what it brings from the DB.

I want lined textboxes to change the height accordingly
ASKER CERTIFIED SOLUTION
Avatar of Mike McCracken
Mike McCracken

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I made it so the line exists in detail only.
I tried to draw line so that it can see in group header, detail, group footer, but crystal does not let me do that
It does in mine so long as the line starts in the group header.

You have to do it in design mode.

mlmcc
are you talking the line?
i'm not talking about line.. I'm talking about the textbox that is used as line by turning on border
A text box can't span sections.  You need to use a line to do that.
The only way a text box can grow is to have the information in them force it larger.

An idea.  Put the same information in the text box and format it so the font color matches the backgorund

A better way .
Delete the text box.
Start a line in the section that is the same height as the text box (design mode)
Right click the line
Click FORMAT LINE
Set the property (as noted above) GROW TO END OF SECTION

mlmcc
The reason that I use the textbox is i need to create a condition where it can be suppressed.
Then you will probably have to try the method using one with data in it, othewise textboxes can't grow.

If you just copy the field you have and set it to font color the same as the background and add the line it should work

mlmcc
It should work in theory.
What happens is that because i have to extend the size of textbox according to the memo textbox,
the white color overwrites one another
Here is the new picture... of my dilemma User generated image User generated image
I just decided to go with your method and use section experts to suppress data, instead of using textbox
>>What happens is that because i have to extend the size of textbox according to the memo textbox,
the white color overwrites one another

You have to make sure the boxes used for the lines don't cover other fields.  You can right click the fields and send them to the BACK.

mlmcc