2009 Jul 14 2:53 PM
Hi All,
I have the following value /1BCDWB/CL_EX_WBTF9D0CDCD5
How can i get the above value to look like /1BCDWB/WBTF9D0CDCD5
I am currently using this
**********************************************************************
DATA: PATT TYPE STRING VALUE `CL_EX_`,
RESULT_TAB TYPE MATCH_RESULT_TAB.
FIELD-SYMBOLS <MATCH> LIKE LINE OF RESULT_TAB.
FIND ALL OCCURRENCES OF PATT IN /1BCDWB/CL_EX_WBTF9D0CDCD5 RESULTS RESULT_TAB.
LOOP AT RESULT_TAB ASSIGNING <MATCH>.
write:/ <MATCH>-OFFSET, <MATCH>-LENGTH "in this case offset is 8, length is 6
ENDLOOP.
**************************************************************************
How can i use the above offset and length values to get a result like /1BCDWB/WBTF9D0CDCD5 ?
Thanks and Regards
Dev
2009 Jul 14 2:57 PM
2009 Jul 14 2:57 PM
2009 Jul 14 2:58 PM
well with offset you could do this, but it´ll be quite a lot of work an brain power.
So i´d propose a way easier solution.
replace all occurences of 'CL_EX_' in lv_your_string with space.
condense lv_your_string.