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

Long String as parameter

I have the following

PARAMETERS: texto(10000) TYPE c.

But it only accept less than 200 characters and I want to receive more.

Is this possible?

Thanx in advance

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

7 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Nov 29, 2005 at 06:02 PM

    Just curious, why do you need such a long parameter ? I am assuming that you need to allow the user to enter variable text descriptions which you can then use in your code.

    Can you instead read in a text file which contains the necessary descriptions & then use it ? I think its cleaner this way & there is no restriction on the text length.

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hello Jose,

      If you want to write an ABAP program, would you be comfortable using a single field of indefinite length where all your code can be written? 😊

      From the usability perspective, don't you think your user would also want to enter the text for the letter in some kind of an editor, something like the one in which you write your program?

      You have got two options -

      1. Provide a text-edit control (refer to Rich Heilman's post below)

      2. Provide a standard text editor (the one where you'd generally write the documentation)

      Regards,

      Anand Mandalika.

  • Posted on Nov 29, 2005 at 06:04 PM

    I think it is not possible.

    regards

    vijay

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 29, 2005 at 06:07 PM

    Hi,

    I dont think thats possible in Abap.

    by the way what do u want the user to enter in a 10000 line width parameter?

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 29, 2005 at 06:23 PM

    A text editor might be good for you here.

    
    
    report zrich_0001 .
    
    data:
          dockingleft  type ref to cl_gui_docking_container,
          text_editor    type ref to cl_gui_textedit,
          repid type syrepid.
    
    data: textlines type table of tline-tdline,
          wa_text type tline-tdline.
    
    parameters: p_check.
    
    at selection-screen output.
    
      repid = sy-repid.
    
      create object dockingleft
                  exporting repid     = repid
                            dynnr     = sy-dynnr
                            side      = dockingleft->dock_at_left
                            extension = 1070.
    
      create object text_editor
                  exporting
                       parent     = dockingleft.
    
    start-of-selection.
    
      call method text_editor->get_text_as_r3table
         importing
               table              = textlines
         exceptions
               others             = 1.
    
      loop at textlines into wa_text.
        write:/ wa_text.
      endloop.
    
    

    Regards,

    Rich HEilman

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 29, 2005 at 06:53 PM

    The text for the letter probably is on the presentation server somewhere - right? So instead of setting the text as a parameter, you could simply upload the file.

    Rob

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 29, 2005 at 10:20 PM

    Hi,

    In selection screen provide a Pushbutton when ever user click the pushbutton provide him with Text editor .

    for example

    data : IT_TLINE TYPE STANDARD TABLE OF TLINE WITH HEADER LINE.

    SELECTION-SCREEN PUSHBUTTON /33(25) PB1 USER-COMMAND 0001. "Details

    AT SELECTION-SCREEN OUTPUT.

    *-- To display the details Form text editor

    PERFORM LAST_PAGE_TEXT

    IF W_UCOMM = '0001'.

    *-- Pass the some header documnet

    WA_HEAD-TDOBJECT = 'FKKKO'.

    WA_HEAD-TDID = 'FKK0'.

    WA_HEAD-TDSPRAS = 'EN'.

    WA_HEAD-TDFORM = 'SYSTEM'.

    WA_HEAD-TDLINESIZE = 72.

    WA_HEAD-TDTITLE = 'Acknowledgement'.

    MOVE-CORRESPONDING WA_HEAD TO WA_NOTIZ-HEAD.

    IF NOT WA_NOTIZ-HEAD-TDTITLE IS INITIAL.

    WA_ITCED-USERTITLE = 'X'.

    ENDIF.

    *-- Call the Text editor

    CALL FUNCTION 'EDIT_TEXT'

    EXPORTING

    DISPLAY = ' '

    EDITOR_TITLE = 'Enter text for last page'(011)

    HEADER = WA_HEAD

    SAVE = ' '

    CONTROL = WA_ITCED

    TABLES

    LINES = IT_TLINE

    EXCEPTIONS

    ID = 1

    LANGUAGE = 2

    LINESIZE = 3

    NAME = 4

    OBJECT = 5

    TEXTFORMAT = 6

    COMMUNICATION = 7

    OTHERS = 8.

    IF SY-SUBRC <> 0.

    • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

    • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

    ENDIF.

    ENDIF. " IF W_UCOMM = '0001'.

    once you trap that in internal table same you can pass to the layout.

    Hope this will help you.

    Thanks

    Rajeev

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 30, 2005 at 04:19 AM

    Hi, as with most of the other responders I have to wonder why you want to do this...but you could have several(many)parameters of 200 and then move their contents into an internal table to work with.

    eg

    PARAMETERS: P_CODE1(200) LOWER CASE.

    PARAMETERS: P_CODE2(200) LOWER CASE.

    PARAMETERS: P_CODE3(200) LOWER CASE.

    etc.

    Another approach would be to use SAP standard texts which are maintained via SO10 and have the name of that as a parameter on your selection screen.

    Add a comment
    10|10000 characters needed characters exceeded

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.