Click here to Skip to main content
15,891,951 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi guys,

i have created one crystal report where i want to write a formula.

my formula:

IF {Sp_Get_DailyReport;1.Job_Status} = 'Workshop' 
THEN {Sp_Get_DailyReport;1.Department_Name}


but, this formula doesn't returning a value.

i have edited my formula, now i'm getting as 'false' instead of Dept-name.
stringvar text := "";
IF {Sp_Get_DailyReport;1.Job_Status} = 'Workshop' 
THEN text = "{Sp_Get_DailyReport;1.Department_Name}"


In ReportFooter i have created one column for workshop where i want to display department name n unit name whose units are in workshop and i'm placing this formula field in ReportFooter where its returns only one value,
instead of each condition where its true.

and

why its returning 'false' i dont know, instead of dept name.

I want to select all those records whose jobstatus is workshop n display it in the reprotfooter.


Can anyone please help me...

Thanks
Posted
Updated 24-Sep-14 2:42am
v10

What is the datatype of
Quote:
Job_Status
.

Check it and then modify the value according to that. Also
Quote:
'Workshop'
can be replaced with
Quote:
"Workshop"


Pls try and let me know.

and also modify THEN text = "{Sp_Get_DailyReport;1.Department_Name}" to

THEN text := "{Sp_Get_DailyReport;1.Department_Name}" and try
 
Share this answer
 
v2
Comments
abdul subhan mohammed 24-Sep-14 3:40am    
Thanks Parida, i have tried all these possibilities, any other sol'n ??
n
still i'm getting only false..
for example if i will get 1 from database i need to display "female" otherwise "male" for that we can write like this

C#
if{SelAppointmentByAppointmentID;1.Gender}=1 then
    "Female"
         else
    "Male"
 
Share this answer
 
v2
Comments
abdul subhan mohammed 24-Sep-14 8:42am    
i think, even my formula is also look as u wrote... it is?
Samatha Reddy G 24-Sep-14 11:25am    
acording to my knowledge the return type should be in string format
abdul subhan mohammed 24-Sep-14 9:08am    
dude, still i'm facing the same... any other solution

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



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900