Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: CrystalReports
if{DataTable1.Amount_Debit}=0 then "NO Amount is credited yet"
else
sum{DataTable1.Amount_Debit}
Posted 16-Jan-13 8:47am
Edited 16-Jan-13 12:00pm
v3
Comments
Christian Graus at 16-Jan-13 16:56pm
   
Do you know what the word 'subject' means ? It means less than 50 chars, summing up your issues. Like 'conditional message in crystal reports'. then tag it as a Crystal Reports question as well as C#, and finally explain where your code comes from, if it runs, what it does, etc. Then you'll have a question that should get answered
zeshanazam at 16-Jan-13 16:59pm
   
i m making formula field. no value in Amount debit field..but "No Amount is credited yet" not displaying...

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

OK - 0 and no value are not the same thing. I suspect Amount_Debit is null and not 0. This code is not C#, I don't know what it is, but I suggest changing your data source to return 0 instead of null, or change the check to also check if it's null.
  Permalink  
Comments
zeshanazam at 16-Jan-13 17:09pm
   
i checked it for null too, but error in formula occured "A number,Currency,boolean,datetime or string is expected here

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 280
1 Sebastiaan Meijerink 145
2 Sergey Alexandrovich Kryukov 108
3 Abhinav S 94
4 BillWoodruff 85
0 Sergey Alexandrovich Kryukov 6,558
1 OriginalGriff 6,268
2 Peter Leow 2,534
3 Abhinav S 2,344
4 Maciej Los 2,297


Advertise | Privacy | Mobile
Web01 | 2.8.150414.1 | Last Updated 16 Jan 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100