Skip to Content
author's profile photo Former Member
Former Member

Help please!!!

Experts help me please...

How can I avoid these scenario::

Everytime I download a file in excel. after '#' character the next text to its right side proceeds to next line.

example:

blue #eyes

excel output:

row 1 blue #

row2 eyes

I need to displayed that text in just one cell.

Gosh!!Ive tried lots of different ways but all of them failed..

my code::

LOOP AT gt_eban INTO wa_eban.

SEARCH wa_eban-txz01 FOR cl_abap_char_utilities=>horizontal_tab.

IF sy-subrc = 0.

REPLACE ALL OCCURRENCES OF cl_abap_char_utilities=>horizontal_tab

IN wa_eban-txz01 WITH ' '.

MOVE wa_eban-txz01 TO wa_output-txz01.

ELSE.

MOVE wa_eban-txz01 TO wa_output-txz01.

ENDIF.

endloop.

Help..

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Posted on Sep 20, 2007 at 06:57 AM

    Dear Salma..

    How are you! well could you send me the whole code if possible i want to debug this. I feel here '#' is considered as tabdiliminator,

    my mail address is nbabi@yahoo.com

    regards

    naeem

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi!

      use this one.

      Search wa_eban-txz01 For '#'.

      if sy-subrc = 0.

      REPLACE ALL OCCURRENCES OF '#' IN wa_eban-txz01 with ' '.

      MOVE wa_eban-txz01 TO wa_output-txz01.

      ELSE.

      MOVE wa_eban-txz01 TO wa_output-txz01.

      ENDIF.

      MOVE-CORRESPONDING wa_eban TO wa_output.

      • SEARCH wa_eban-txz01 FOR cl_abap_char_utilities=>horizontal_tab. <-- it look for the #

      • IF sy-subrc = 0. <--- value is getting changed with 4.

      • REPLACE ALL OCCURRENCES OF cl_abap_char_utilities=>horizontal_tab

      • IN wa_eban-txz01 WITH ' '. <---- this is not executing.

      • MOVE wa_eban-txz01 TO wa_output-txz01.

      • ELSE.

      • MOVE wa_eban-txz01 TO wa_output-txz01.

      • ENDIF.

      *

      • MOVE-CORRESPONDING wa_eban TO wa_output.

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.