Solved

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

Posted on 2008-06-21
5
434 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 250 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 250 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

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

A basic question.. “What is the Garbage Collector?” The usual answer given back: “Garbage collector is a background thread run by the CLR for freeing up the memory space used by the objects which are no longer used by the program.” I wondered …
This article describes relatively difficult and non-obvious issues that are likely to arise when creating COM class in Visual Studio and deploying it by professional MSI-authoring tools. It is assumed that the reader is already familiar with the cla…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

758 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

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now