Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: Custom null value Post Reply Post New Topic
Author Message
mh9876
Newbie
Newbie


Joined: 24 Dec 2017
Location: United States
Online Status: Offline
Posts: 6
Quote mh9876 Replybullet Topic: Custom null value
    Posted: 15 Feb 2018 at 5:36am
I'm trying to convert the null values of numeric field as '-'. My numeric field is formatted with currency '$'.
When I use the default setting to '-'. The null value appears as '$-'. However, I want it to appear as '-'.

The following code works for the string field. However, when I try this for the numeric field I get error message that a "number is required".

If IsNull({Command.NUMERIC_DATA_01}) OR {Command.NUMERIC_DATA_01} = ' ' Then '-' Else {Command.NUMERIC_DATA_01}

Please guide me as to how I can make this working on the numeric field. Thanks


Edited by mh9876 - 15 Feb 2018 at 5:42am
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 26 Feb 2018 at 7:01am
set the formula to use default values for nulls

if {Command.NUMERIC_DATA_01}=0 then "-" else totext({Command.NUMERIC_DATA_01})
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.016 seconds.