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

Simple?

edited May 2004 in End User
Hello

I have created a report that only write one post for each page and I want to
hide and show Labels and fields depending on the context of
DBText values,

Sample
If DBText9.Text = 'Something' or DBText9.Text = ' ' then
begin
Label9.Visible := False
DBText8.Visible := False
else
Label9.Visible := True
DBText8.Visible := True
end;


Is it possible? And what event to use if the fields are in the detail band?

Thanks in advance?

Newbe from Sweden

Comments

  • edited May 2004
    Hi Stig,

    You're going to want to use the Band.BeforePrint event to do something like
    this (most likely the DetailBand.BeforePrint). Instead of checking the
    DBText9.Text value, go ahead and check the actual record value. For
    instance...

    lsText := Report.DataPipeline['FirstName'];

    if (lsText = 'Nico') or (lsText = '') then
    DBText9.Visible := False
    else
    DBText9.Visible := True;

    --
    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited May 2004
    Thanks a lot!
    May all trafficlights be green for you :)


    /Stig
This discussion has been closed.