Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Text field position change based on another field's can grow state

Status
Not open for further replies.

tropisms

Programmer
Apr 1, 2010
3
US
Hi,

Let's say I have a company name and a cost field on a detail section of a report (CR XI), the company name is set to can grow = true. I'm trying to get the cost field to be at the bottom of the detail section, so it lines up with the last line of the company name instead of the first line, no matter how many lines it grows to.

A coworker mentioned parsing the company name into a couple sections (based on the spaces as not to break up the words in the company name), then have a cost field on every section and make them visible only when it is the last line.

Does anyone know of a less terrible way to do this? Some way to anchor the data field or something? Thanks!
 
Are your detail lines in a group? Or could a group be added? The group footer is the normal place for such things.

[yinyang] Madawc Williams (East Anglia, UK). Using Crystal 10 & 11.5 with Windows XP [yinyang]
 
I think your coworker's idea is the best approach.

-LB
 
Madawc - The detail lines are in a couple groups, I'm not sure I see how putting it in the footer would help.

IBass - I was afraid that might be the case, thanks!
 
Does the cost field HAVE to be aligned? One simple workaround would be to concatenate the two fields with a carriage return so that the cost would be just under the company name. Just a thought.
 
Sadly yes, the cost field does have to be aligned, there is actually more than one field that needs to be aligned, but I left that out for simplification.
 
You could actually concatenate on the last item in the string--without adding a return, but instead adding tabs or spaces, and it would always be on the same line. It's just that the alignment wouldn't be consistent across records.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top