on 03-14-2007 7:52 AM
Hi Experts,
I want to display all the negative value, in a bracket.
For e.g., The Output value from a Driver Program is 1000- or -1000. But i want to display it as (1000) and the font color should be Red.
I don't want to insert any program statement, inside smart forms, for doing this.
Whether any other formatting option is available, for doing this?
Thanks in Advance.
Vijay G
Hi,
If you don't want to do this in the Program Statement and you need to modify the internal table only in the print program.
while updating the internal table itself with the values do this.
if wa_itab-value < 0.
concatenate ' (' wa_itab-value ')' into wa_itab-value.
append wa_itab to itab.
endif.
Br,
Laxmi.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi Vijay,
have u concidered my previous post. any way u have to modify the data. it can't be possible with formating options.
you can do it in the smartform GLOBAL DIFINATIONS-->INITIALIZATIONS .
if u r unable to change the ITAB structure u r using presently then create another ITAB same as existin but with extra field.
Please Close this thread.. when u r problem is solved
Reward if Helpful
Regards
Naresh Reddy K
hi vijay
even if you don;t want to modify the ITAB then follow the laxmi sloution.... I want to add something here
USE
<b>(' &WA_ITAB-VALUE(S)& ')'.</b> to remove the operator.
in this case u have to create 2 text elements in 1st one CONDITIONS tab give WA_ITAB-VALUE > 0. here print <b> &WA_ITAB-VALUE&.</b>
and for the second text element give the condition WA_ITAB-VALUE < 0. in this print <b>(' &WA_ITAB-VALUE(S)& ')'.</b>
hope ur problem will be solved
hi
I don't think there are formating options for this.
any way you need to modify the value either by using the program lines or modifyling the ITAB.
if you don'r want to use the program line in the table.. then modify the ITAB bye maintaining Extra char type field in the ITAb. then in the INITIALIZATION tab..
loop the itab into wa_itab.
if wa_itab-num < 0 .
concatenate '(' wa_itab-num ')' into wa_itab-chrtypfield.
else.
wa_itab-chrtypfield = wa_itab-num.
endif.
modify itab from wa_itab.
endloop.
in the table printhe char type field instad of nuber field.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.