Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Reports

Former Member
0 Likes
267

Hi friends,

In my report there r few Doc types ZA05 & ZCF2 for

Which i have to multiple by -1 .

But the requirement is to display the negative value in hard core.

Can any one help me...

pls send me a sample code..

1 REPLY 1
Read only

Former Member
0 Likes
245

Hi,

Use this macro in your program :

define format_amt.

write &1 to g_amt_out currency &2 left-justified no-sign.

if &1 lt 0.

concatenate '-'

g_amt_out

into g_amt_out.

endif.

shift g_amt_out right deleting trailing space.

end-of-definition.

I hope you know that &1 and &2 are placeholders.. So, when you have to use this on an amount, just use it as:

format_amt <amount-field> <currency-field>

eg: format_amt 1000 'EUR'.

Reward points pls..

Rahul