2008 Sep 30 10:27 AM
Hi,
I have a text field in which I want to replace a string with an amount value. while am trying to replace it , it gives me some empty space.
For example:
amount = '1200 '
message = 'The STIP amount is &1'
in my code :
replace &1 with message into message.
the result is
'The STIP amount is 1200 '
I dont want the space after 1200.
I tried for condense no-gaps also but it is not working ..
What may be the problem?
Can you suggest some solution for this?
Regards,
Vimala
2008 Sep 30 10:33 AM
Hi,
First move to asmount field into char type. after do the condense, and try to replace.
Regards
Jana
2008 Sep 30 10:34 AM
2008 Sep 30 10:56 AM
Hi Friend,
I think the space is from the amount field:
Meth 1. Transfer the amount value to character, then condense and concatenate with your text
Meth 2. Or use this statement to remove the space at the end SHIFT text right deleting trailing space.
Regards,
Jey
2008 Sep 30 10:58 AM
Hi,
replace &1 with message into message.
I guess its replace &1 with amount into message.
Convert the amount to a character type (example move amount to amount_c ), then condense it and and then replace it using the 'REPLACE' statement.
regards,
Advait.