Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to make a field visible false on Report 2

Status
Not open for further replies.

AuctionLamb

Programmer
Feb 16, 2005
65
ZA
Hi guys!!

How do I make a field visible false in Crystal Reports(v8.5)? For example: When I get a ProcessDate back then it must hide the DueDate AND when ProcessDate = empty I want to hide the ApprovedCost field and UNHIDE the DueDate.

It is very simple logic but can't seem to get to work on the report? HEEEELLLPPPP!!!!!

THANKS!!!
 
You put conditional suppression formulas into the fields that might be suppressed.

So for the DueDate field you will have something like:

if isnull(mytablename.processdate} then
false //don't suppress
else
true //suppress
 
I just tried using that formula lupin46 .. some reason it didn't work.

I did this:

In DueDate Properties, go to x-2 next to suppress
Len({ProcessDate}) > 0

For ProcessDate do this:
Len({ProcessDate}) <= 0

That seems to work fine on a sample report I just did...

The IsNull should have technically worked, but it may be the way our data is in our DB2 system??? hhmmm
 
THANKS!!

But what will I put into the DueDate? Soooooo confused now, I also understand your logic but ALL my fields are dissapearing now. I think it is because when I get a blank processdate my DueDate is not appearing.
 
Who are you responding to? me or lupin46 ?

Also ... That's what you asked for in your initial post
When I get a ProcessDate back then it must hide the DueDate

You need to give more detailed information, cause that's what I thought you wanted to do...
 
Hi DallasAggie!

THANKS!
I am getting a "A STRING IS REQUIRED HERE" message?
 
You should have a formula in the ApprovedCost field suppression button and a formula in the DueDate field suppression button. There is nothing to do in the ProcessDate button.

Be clear that the button you are using is a 'Suppress' button NOT a 'Visible' button, so if the result of the test is True then the field will be suppressed; if it is false the field will be visible.
 
oops:

Code:
For ProcessDate do this:
Len({ProcessDate}) <= 0
.. my bad!

lupins46, thanks for catching that....the suprress logic needs to be in your ApprovedCost field...
 
THANKS BOYZ!!!

Help much appreciated!!!!!!!!!!!!!!!!!!!!!!!!!
 
If you did a Boolian - Formula Field that said isnull{ProcessDate} - then it would automatically return true pr false. If it was called @DateVoid, you could then test if @DateVoid in some other formula, getting the same effect as if @DateVoid = true. For false, say if not @DateVoid.

[yinyang] Madawc Williams (East Anglia, UK) [yinyang]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top