Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Conditional Suppression based on Boolean Value Post Reply Post New Topic
Author Message
adavis
Senior Member
Senior Member


Joined: 30 Oct 2012
Online Status: Offline
Posts: 104
Quote adavis Replybullet Topic: Conditional Suppression based on Boolean Value
    Posted: 13 May 2013 at 5:15am
Hello CR users.

I am trying to find a way to suppress a detail section based on a boolean value. What I would like to do is have an entire section be suppressed if the boolean value is false. Is there a way to do this? I tried tooling around with If/Then/Else statements, but since "suppress" does not appear to be a function, I am lost.

Tips appreciated.
Thanks!

Edited by adavis - 13 May 2013 at 5:16am
IP IP Logged
kevlray
Admin Group
Admin Group
Avatar

Joined: 29 Oct 2009
Online Status: Offline
Posts: 1587
Quote kevlray Replybullet Posted: 13 May 2013 at 5:29am
Yes in the section expert, look for the formula button for suppress (remember a true suppresses the section.
IP IP Logged
adavis
Senior Member
Senior Member


Joined: 30 Oct 2012
Online Status: Offline
Posts: 104
Quote adavis Replybullet Posted: 13 May 2013 at 6:01am
Thanks. I figured out how to make it work there. For any other newbies who reads this and are curious about the same thing, here is the fix I came up with.

I selected all the fields in the detail section I wanted conditionally suppressed, right clicked and selected format field. Under the common tab, I opened the suppression formula window and entered the conditional suppression statement for the boolean field I wanted the conditional suppression based on (ex: {xfield}=true). Then I went to the Section Expert and clicked the suppress blank section button for the details section I was interested in.

Now when the boolean field returns a true result, the entire detail section is suppressed.

I'm not sure if this is the most efficient way to achieve the result I was looking for, but it worked!
IP IP Logged
kevlray
Admin Group
Admin Group
Avatar

Joined: 29 Oct 2009
Online Status: Offline
Posts: 1587
Quote kevlray Replybullet Posted: 13 May 2013 at 7:19am
You should have been able to put the same formula in the section expert, suppress formula area.  Which is more efficient? I have no idea.
IP IP Logged
adavis
Senior Member
Senior Member


Joined: 30 Oct 2012
Online Status: Offline
Posts: 104
Quote adavis Replybullet Posted: 13 May 2013 at 7:56am
Yeah that would have been easier! lol Live and learn. Thanks kevlray!
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.031 seconds.