How to set currency pattern along with color chang

0

Hi All,

We have a doubt ..

How to set currency pattern in iReport .On the generated excel sheet default existing values as well as on user updation positive value should be represented as  $ xxxxxx.xxx  ,negative value ($xxxxxx.xxx) in red.

We tried the below pattern

$#,#####0.00_);[Red]($#,#####0.00)

This works for the below values :

  $0.000

$x.000

$xx.000

$xxx.00

If we remove 1000's seperator it works for thousand values, it fails for lakh values.Why?

i.e.,For bigger values the color change is not happening on the Excel sheet

Please guide us with your valuable suggestions at the earliest.

 

Thanks,

Ani

honeyani's picture
Joined: Sep 10 2008 - 3:07am
Last seen: 6 years 3 months ago

3 Answers:

0
Please find a detailed description about the issue faced as below.. Output obtained: Revised Budget / Encumber ($10.00) (red) ($10000.00) (red) ($20.00)(red) ($10,030.000)(red) ($1.60)(red) [Red] $0.00 (black) In iReport tool custom pattern that we have specified for Revised Budget text field placed in detail band is as below : $######0.00_);[Red]($######0.00) We require a color change to red if user updates the field value as a negative number and if user enters positive input the value should be in black as above. We use XML file as Data source here , When the value is in lakhs ,its not displayed in excel sheet instead we get ‘[Red] ‘ as in 6th row .What is the reson behind? Any ways to set this color change option to the mentioned field? Requirement : Positive values should be represented in black color as in 7th row,negative value shoud be represented in red color along with braces as in 1-5 rows. Any mistake in the way we are setting the patter? Waiting for your reply.. Thx, Ani
honeyani's picture
Joined: Sep 10 2008 - 3:07am
Last seen: 6 years 3 months ago
0

Avoid my previous reply - formatted one i'm pasting  here...

Please find a detailed description about the issue faced as below..

Output obtained:

Revised Budget / Encumber

($10.00) (red)

($10000.00) (red)

($20.00)(red)

($10,030.000)(red)

($1.60)(red)

[Red]

$0.00 (black) I

n iReport tool custom pattern that we have specified for Revised Budget text field placed in detail band is as below :

$######0.00_);[Red]($######0.00)

We require a color change to red if user updates the field value as a negative number and if user enters positive input the value should be in black as above. We use XML file as Data source here , When the value is in lakhs ,its not displayed in excel sheet instead we get ‘[Red] ‘ as in 6th row .What is the reson behind?

Any ways to set this color change option to the mentioned field? Requirement : Positive values should be represented in black color as in 7th row,negative value shoud be represented in red color along with braces as in 1-5 rows.

Any mistake in the way we are setting the patter?

Waiting for your reply at the earliest..

Thx, Ani

honeyani's picture
Joined: Sep 10 2008 - 3:07am
Last seen: 6 years 3 months ago
0

Hi  All,

I fixed this issue on my own.

Just have set 'net.sf.jasperreports.print.keep.full.text' to true for custom element property  on iReport tool.

It works fine now.

Thanks,

Anitha

 

honeyani's picture
Joined: Sep 10 2008 - 3:07am
Last seen: 6 years 3 months ago
Feedback