Home End User
New Blog Posts: Merging Reports - Part 1 and Part 2

DBMemo acting strange

edited August 2006 in End User
The component is getting its data from a Memo field in Interbase. What
happen is, during printing, the text wrap to the next line eventhough the
DBMemo box length is still long enough to fit it all in one line.

Comments

  • edited August 2006
    Hi Muhamad,

    If you increase the width of the memo to something very large (i.e. the
    width of the page) do you still get this behavior? Does the memo always
    break in the same spot? If so, you might check that the memo text you are
    retrieving from your database and be sure there are no CRLF characters
    present.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited September 2006
    Hello,

    we have the same problem with a memo. The data of the memo is calculated
    on a OnPrint-Event of a DBText-component. That's the code:

    if Memo1.Text <> '' then
    Memo1.Text := Memo1.Text + ', ';
    Memo1.Text := Memo1.Text + Table1['DataField1'];

    The preview looks like that: The text wraps to the next line after each datafield
    contents. The length of the memo is long enough and there are no CRLF characters
    in the text.

    Where is the mistake?

    Any feedback would be greatly appreciated.

    Regards,

    Silke
  • edited September 2006
    Hi Silke,

    Do not use the Memo.Text property to define the memo text. Rather use the
    Memo.Lines TStringList property. Take a look at demo 33 located in the
    \RBuilder\Demos\1. Reports\... directory (dm0033.pas) for an example of what
    you are trying to do.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
This discussion has been closed.