Solved

Conditional Printing in Crystal Report

Posted on 2008-10-10
2
1,101 Views
Last Modified: 2008-10-24
Hi Experts,

 I am designing a Crystal report where I need to print some labels conditionally, means If certain condition is true then only those labels should get displayed in the report else they should not. I am using Crystal Report 9.0.

My question is

1) Is it Possible?

2) If it is Then How to do it?


I want ask one more thing about crystal report. In the crystal report i hv taken two groups for different fields, every thing is working fine except for one. I hv used order by purchasedate clause in the query. I hv tested the query in backend its working fine there. But in the crystal report order by clause in not working. It is displaying the dates in random order. i dont know why its happening. Can any body tell me whats the reason and how to solve it.

Please help me out.

Thanx in advance.

Regards
Param
0
Comment
Question by:Paramhans
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 6

Accepted Solution

by:
divyeshhdoshi earned 300 total points
ID: 22685159
Hi

Yes it is possible

right click on lable >> Format object >> Common Tab >> check Suppress >> click on Formula button of Suppress.
write formula for displaying that lable

eg.
if (i>0)
true
endif
0
 
LVL 101

Assisted Solution

by:mlmcc
mlmcc earned 200 total points
ID: 22687097
As above you can suppress fields conditionally.

The condition you use will suppress if it evaluates to true so if you have a condition that when true you want to display the label then you have to negate the condition in the suppression formula.

Using the above example if you wanted to display when a given field is positive you would suppress with

{YourField} <= 0

Data order.
Crystal uses the groups for the first sorting fields.

If you want it then in date order within the group you can
Click DATABASE --> RECORD SORT EXPERT
Add teh date field to the sort order.

mlmcc
0

Featured Post

Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

Question has a verified solution.

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

JSON is being used more and more, besides XML, and you surely wanted to parse the data out into SQL instead of doing it in some Javascript. The below function in SQL Server can do the job for you, returning a quick table with the parsed data.
Slowly Changing Dimension Transformation component in data task flow is very useful for us to manage and control how data changes in SSIS.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.

615 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