Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Display contacts of a formula Post Reply Post New Topic
Author Message
Central
Groupie
Groupie


Joined: 16 Feb 2011
Online Status: Offline
Posts: 56
Quote Central Replybullet Topic: Display contacts of a formula
     Posted: 04 Feb 2013 at 5:15am
Hi,
 
I have a formula as follows
 
if {Code} = 'SP' then "Staff Member" else
{@ContactAddress}  + CHR(13) +
{@ContactTelphone}
 
What I want to display is, if there is no entry {@ContactAddress}  then display {@ContactTelphone} and vice versa. 
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 04 Feb 2013 at 8:23am
are these two items mutually exclusive? meaning one is always blank while the other is always not blank? if not and you can have items in both then how is this supposed to look?

Edited by DBlank - 04 Feb 2013 at 11:38am
IP IP Logged
Central
Groupie
Groupie


Joined: 16 Feb 2011
Online Status: Offline
Posts: 56
Quote Central Replybullet Posted: 04 Feb 2013 at 9:36am
Hi,
 
Thanks for getting back to me.
 
One could be blank or both could have data in them or both could be blank.
 
 
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 04 Feb 2013 at 11:41am
I still am not sure what all of your rules are.
Is the problem that when one is blank that it returns nothing?
If that is the case then you are dealing with nulls. Open the formula and in the editor there should be an option with a pick list of how to handle nulls. Make sure it is set to 'use default values for nulls'.
IP IP Logged
Central
Groupie
Groupie


Joined: 16 Feb 2011
Online Status: Offline
Posts: 56
Quote Central Replybullet Posted: 05 Feb 2013 at 12:06am
Hi,
What you suggested worked.
 
A big thank you for your answer and helping me.
 
Regards
 
Central
IP IP Logged
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