?
Solved

Crystal Reports formula for detail field value "1" to equal OK.

Posted on 2008-06-21
5
Medium Priority
?
451 Views
Last Modified: 2013-11-26
I am using visual studio crystal reports.
A crystal reports detail field receives a value of "1" from a .net checkbox by default.
I need a sample formula for the detail field value "1" to convert to the value "OK".

If the .net checkbox is unchecked the detail field would show no value.

Thanks
0
Comment
Question by:dave_sky
  • 2
  • 2
5 Comments
 
LVL 13

Accepted Solution

by:
crgary_tx earned 1000 total points
ID: 21837799
create a formula:
//@ok
if {table.field} = 1 then 'OK'
else
""

hth
Gary
0
 

Author Comment

by:dave_sky
ID: 21837965
Thanks for the response.

I used this formula:
if{tblSprinklerWorkorderDetail2.FunctionOK} = 1 then 'OK'
else
""
I get an error message - The result of selection formula must be a boolean.
0
 
LVL 8

Assisted Solution

by:RickJ
RickJ earned 1000 total points
ID: 21839412
I think you have put the formula in a selection formula.
You need to create a formula field and drop it on the report.
In your field explorer right click on Formula Field and click "New"
Once it is created, drag from the explorer to your report.
0
 

Author Comment

by:dave_sky
ID: 21839473
RickJ,

You are so right. I was trying to create the formula in a selection formula.

Thanks for the rescue!
0
 
LVL 8

Expert Comment

by:RickJ
ID: 21839590
Thanks,
Glad I could help.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
As many of you are aware about Scanpst.exe utility which is owned by Microsoft itself to repair inaccessible or damaged PST files, but the question is do you really think Scanpst.exe is capable to repair all sorts of PST related corruption issues?
Suggested Courses

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question