2007 Dec 28 5:48 AM
dear,
"Line 2, Item #50006632: Vendor to pay half the cost for replacement of incorrrect product. The unit of measure is also incorrect. It is listed as SET and should be Each. Thank You"
this is my string from item text of po.which is getting from read_text call -function.
now ,
i have to display this text as
'Line 2, Item #50006632: Vendor to pay half the
cost for replacement of incorrrect product
The unit of measure is also incorrect.
It is listed as SET and should be Each. Thank You''
that is it should break after 35 character.
and OUT-PAR as
TEXT1,
TEXT2,
TEXT3,
TEXT4.
so that it should have 35-38 character length.
one below other.
dear,
"Line 2, Item #50006632: Vendor to pay half the cost for replacement of incorrrect product. The unit of measure is also incorrect. It is listed as SET and should be Each. Thank You"
this is my string from item text of po.which is getting from read_text call -function.
now ,
i have to display this text as
'Line 2, Item #50006632: Vendor to pay half the
cost for replacement of incorrrect product
The unit of measure is also incorrect.
It is listed as SET and should be Each. Thank You''
that is it should break after 35 character.
and OUT-PAR as
TEXT1,
TEXT2,
TEXT3,
TEXT4.
so that it should have 35-38 character length.
one below other.
2007 Dec 28 5:55 AM
2007 Dec 28 5:58 AM
Hi ,
Can you tell me where do you want to display this text, means in a report or some thing,
please let me know.
because once you have it in you TDLINE structure you can easily break the sentence with proper offsets.
regards,
taher
2007 Dec 28 6:02 AM
hi ,
It should be like
text1 = tdline +(35)
text2 = tdline+36(35)
text3 = tdline+71(35)
syntax is like
text = tdline +from_position (how many characters)
2007 Dec 28 5:59 AM
In ur form painter the coding should be something like this in order to truncate the line at 35 th character
if itab-tline+0(35) ne ' '.
endif.
if itab-tline+35(35) ne ' '.
endif.
if itab-tline+70(35) ne ' '.
endif.
This will capture string offset of 35 line wise.
Vijay
2007 Dec 28 6:06 AM
Hi,
If you are working on single byte char (ex: english) you can break the text directly by using offsets.
In ur case :
Text1 = l_f_string+0(35).
Text2 = l_f_string+35(35).
Text3 = l_f_string+70(35).
etc..
If you are working on multiple byte char (ex: Japanese), then use FM :TRUNCATE_MULTIPLE_BYTE_STRING to find proper place to truncate the string.
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |