Application Development 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: 

Printing Format in CURR Type

former_member203806
Participant
0 Kudos

Hi All,

I am passing CURR value to my smart form. i need to print that value inside ( ) . but when it is print in smartform leading and trailing spaces showing.

how i can remove those spaces print in smartform.

Thanks]

pramod

12 REPLIES 12

Former Member
0 Kudos

Hi,

While passing the value in the (), first you can pass it to a char field of the same length and condense the variable. after that you can pass it.

data: gv_curr(16) type c.

gv_curr = curr.

condense gv_curr.

Hope this helps.

0 Kudos

Hi Gaurav,

after  condense the C variable, is it pass to CURR variable again before print smartform?

Thanks

pramod

former_member185414
Active Contributor
0 Kudos

It is because smartform is reserving the space for the entire length of the field whose type is decimal.

Suggestion of Gaurav is a possible workaround. Further read is here -

http://help.sap.com/erp2005_ehp_04/helpdata/en/1c/f40c6fddf311d3b574006094192fe3/content.htm

former_member203806
Participant
0 Kudos

HI all,

I have pass CURR value to Char Variable, Condense it, pass it again to CURR variable, print in smartform. now it is showing as below.

how i can remove highlighted spaces.. pls advice.

0 Kudos

Hi Pramod,

Copy your data of CURR type into one CHAR variable and then use CONDENSE on this CHAR variable. And then print

this CHAR variable with the style defined for printing right aligned data.

Regards,

Hitesh

0 Kudos

HI Hitesh,

i need to put thousand separators also, for CHAR type  how i can put Separators.

Thanks

Pramod

0 Kudos

CONCATENATE char1 char2 INTO result SEPARATED BY space.

0 Kudos

Hi

i mean thousand separator Comma ( Eg : 2,000).

0 Kudos

Try write statement with edit mask.

Hope this helps.

0 Kudos

write : char to fnchar.

hitesh_gabani
Participant
0 Kudos

Hi Pramod,

Copy your data of CURR type into one CHAR variable and then use CONDENSE on this CHAR variable.


Define CURR type field in your smart form for currency display.

Example,

Regards,

Hitesh

VenkatRamesh_V
Active Contributor
0 Kudos

Hi Pramod,

Try,

&bseg-dmbtr(CIZ)&.

Hope it helpful,

Regards,

Venkat