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

Use a field to choose between two other fields

edited June 2001 in General
On detail band I have a DBText Field bounda to a field called Status.
Based on Status where would I put code that would allow me to choose either
of a two other fields.

what to use to show the value new selected field.


i.e.

if status = open then
show field1
else
show field2;

Thanks

Comments

  • edited June 2001
    Create a calculated field in the dataset.

    Ed Dressel
    Team DM
  • edited June 2001
    Ed-

    Are there disadvantages to using a TppLabel or TppVariable and providing the
    Caption or Text property either in the GetText event of the component or the
    BeforePrint event of the band?

    Thanks,

    Les

  • edited June 2001
    Another option is to toggle the visible property of two labels.


    Cheers,

    Jim Bennett
    Digital Metaphors


  • edited June 2001
    Les:

    Sorry about the late response.

    My strucutre is to save all of my reports to a DB table. I do not like to
    have any code/events in my applications that relates any particular report.
    To date, with around 100 reports, I do not have a single line of code for
    any report in my code (and I am not using RAP, yet). This keeps my report
    handeling mechinism to a minimum, and the code is very clean.

    So I would lean towards using calculated fields because of this. If your
    structure is different (different forms, different reports), then either
    method would work for you.

    Ed Dressel
    Team DM


This discussion has been closed.