Writing Code
 Crystal Reports Forum : Crystal Reports for Visual Studio 2005 and Newer : Writing Code
Message Icon Topic: conditional more then 1 Post Reply Post New Topic
Author Message
ismailkoca
Newbie
Newbie
Avatar

Joined: 14 Sep 2008
Location: Turkey
Online Status: Offline
Posts: 5
Quote ismailkoca Replybullet Topic: conditional more then 1
    Posted: 11 Oct 2008 at 4:09pm

i can 1 conditional by using formula like ; if({deneme.deneme2} in 11 to 88) then "you're good"

but i can't do contional more then 1 like;
if({deneme.deneme2} in 11 to 88) then "you're good"
({deneme.deneme2} in 89 to 118) then "you're so good"
 
i want to do 1 formulafield but 2 pr 3 conditional
Sorry for my poor English.
 
Thank U


Edited by ismailkoca - 11 Oct 2008 at 4:17pm
www.cokluzeka.net
IP IP Logged
BrianBischof
Admin Group
Admin Group
Avatar

Joined: 09 Nov 2006
Online Status: Offline
Posts: 2458
Quote BrianBischof Replybullet Posted: 13 Oct 2008 at 11:54am
You can do this by adding the "Else If"keyword to your logic. Here is sample code:
IF ({deneme.deneme2} in 11 to 88) then
    "you're good"
ELSE IF ({deneme.deneme2} in 89 to 118)  then
    "you're so good"
ELSE IF ({deneme.deneme2} in 119 to 200) then
    "you're the ultimate in good";
I have the complete Crystal syntax documented with sample code in my Encyclopedia book. You can find out more about my books at Amazon.com or reading the Crystal Reports eBooks online.
Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>
IP IP Logged
ismailkoca
Newbie
Newbie
Avatar

Joined: 14 Sep 2008
Location: Turkey
Online Status: Offline
Posts: 5
Quote ismailkoca Replybullet Posted: 13 Oct 2008 at 3:07pm
Thank U 4 ur reply,
but i have a new problem,
i can do
IF ({deneme.deneme} in 11 to 88) then

    "you're good"

and ({deneme.deneme2} in 11 to 88)  then
" you're so good"
 
how can i do it.
 
Thank U very much.
www.cokluzeka.net
IP IP Logged
BrianBischof
Admin Group
Admin Group
Avatar

Joined: 09 Nov 2006
Online Status: Offline
Posts: 2458
Quote BrianBischof Replybullet Posted: 13 Oct 2008 at 7:02pm
I don't understand your question. You test for "11 to 88" two times with differerent results. Did you put the wrong numbers in the second part? Shouldn't it be 89 to 118? And why did you put the "AND" in there? Confused...
Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>
IP IP Logged
Savan
Senior Member
Senior Member
Avatar

Joined: 14 Dec 2007
Location: India
Online Status: Offline
Posts: 162
Quote Savan Replybullet Posted: 14 Oct 2008 at 2:29am
u can do it this way
 
IF ({deneme.deneme} in 11 to 88) and ({deneme.deneme2} in 11 to 88) then
    " you're so good"
else
    "you're good"
Thanks
Savan
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.015 seconds.