Recent

Author Topic: Stretched Behavior Observed  (Read 2417 times)

sbauman

  • Newbie
  • Posts: 2
Stretched Behavior Observed
« on: September 04, 2012, 01:14:12 am »
I've observed the following behavior in trying to include a Memo with a variable number of lines in a LasReport.

First, the only way I as able get a variable number of lines displayed in the Memo was to create a text field in the query that yielded a variable number of lines. I'm using Postgresql. I can insert a chr(10) a linefeed either by using a stored function in the database or by concatenating it in the SQL. I've not been able to alter the Memo text through programming while the LazReport is being generated.

However, having generated a Memo with a variable height, my next wish was to use as little paper as possible in printing it. I set the the Stretched properties in both the MasterData band and the Memo.

I noticed the following undocumented behavior.  Stretched works ONLY when the Memo field height is set to 2 lines long in the Designer.

If you set the Memo field height to only 1 line height and try to show/save a field with 2 or more lines, then only the first line will show. However, if you set the Memo field height to 2 lines in the designer then 2 lines will show as designed. The Memo field and band will stretch when the database field presents 3 or more lines. Also, adjacent Memo fields in the same band with display lines will also be stretched.

Did I  miss this in the many volumes of documentation?

I don't know if this is a design feature, artifact or bug. However, I'm presenting this as a work around, for others.