473,396 Members | 1,764 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Problem in crystal report null value

Hello everyone,
I hav been facing a problem since a few days. I'm using crystal report with .net 2005 (.Net framework 2.0). In a report I'm retrieving the values from a database table and showing it. But the problem is that if a certain field is blank in database then it's showing a complete blank white field in the report also. This is what I don't want. For example- suppose there's a field in datbase named EntryDate which is not mandatory. So for a certain row if there's an entry for EntryDate it'll show it in the report otherwise if it's blank or null in database it'll show a user defined string in the report say 'Not Available' or something like that. For this I hav tried playing with the ZeroValueString property of the respective field in the crystal report also but of no avail. How can I solve it. Plz help with some code example.
Regards.
Sep 24 '08 #1
1 2482
On Sep 24, 10:08 am, Priyam Ganguly wrote:
Hello everyone,
I hav been facing a problem since a few days. I'm using crystal report with .net 2005 (.Net framework 2.0). In a report I'm retrieving the values from a database table and showing it. But the problem is that if a certain field is blank in database then it's showing a complete blank white field in the report also. This is what I don't want. For example- suppose there's a field in datbase named EntryDate which is not mandatory. So for a certain row if there's an entry for EntryDate it'll show it in the report otherwise if it's blank or null in database it'll show a user defined string in the report say 'Not Available' or something like that. For this I hav tried playing with the ZeroValueString property of the respective field in the crystal report also but of no avail. How can I solve it. Plz help with some code example.
Regards.
You have two options, you can either modify the query to return the
value you want instead of null using coalesce:
select coalesce( myColumn, 'N/A') ...

or you can modify how the field is displayed in the screen, you can
create a formula and take care of this in the report designer
Sep 24 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Max | last post by:
Hi wise people, Has anyone encountered the Crystal Reports problem I describe below? If so, how did you solve it? It seems that every article posted on google regarding CR and logon problems is...
3
by: michael haller | last post by:
In my project i have a textfile witch i import in my c# application. The datas in the textfile i show the datas in the textfile in my datagrid..ok that ist not my problem. Now i have a...
0
by: mharris | last post by:
I need help with merging two Word documents into one through C# code. The problem isn't so much getting the documents put into one as it is maintaining the appropriate formatting, or rather...
0
by: Henry | last post by:
Using ideas provided by some of you I was able to figure out how to get the names of the parameters fields of a crystal report specified at run time. The code below just basically puts the...
2
by: PK | last post by:
Hi, I have an application that opens a Crystal report document and passes in a value to a parameter in the report (pointing to an Oracle DB). However, if I want to pass a "null" value to retrieve...
1
by: Hardy Wang | last post by:
Hi all, I have a piece of code in my C# console application to export from crystal report files to PDF. For some reports files, I get errors below. I have Crystal Reports 8.5 with service pack...
0
by: Jeff | last post by:
Help!!! The bitmap I am trying to display in a sample Crystal Report is coming up with much less quality than the original bitmap. I have a 300x300 dpi bitmap file that I want to insert at run...
7
by: Jlo | last post by:
Hi, I have a c# winforms application. When I call the report file, it shows me all the records in the table. How can I make it to call only a particular range. i have the following code...
1
by: Priyam Ganguly | last post by:
Hello everyone, I hav been facing a problem since a few days. I'm using crystal report with vb.net 2005 (.Net framework 2.0). In a report I'm retrieving the values from a database table and showing...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.