Display more than 1023 Columns in alv

can we display more than 1023 columns in alv. please provide inputs on any approach that can be followed to achieve this.
Thanks.

Hi,
just for the record. Here's the code to create a table with 10000 columns, in this example all of type vendor. It could be modified a little to create any dynamic table. Without any visible limits and can be displayed in SALV.
DATA:
    lv_lifnr       TYPE lifnr,
    lv_numc7       TYPE numc7,
    lt_components  TYPE cl_abap_structdescr=>component_table,
    lo_struc_descr TYPE REF TO cl_abap_structdescr,
    lo_tdescr      TYPE REF TO cl_abap_tabledescr,
    lr_tab         TYPE REF TO data.
  FIELD-SYMBOLS:
    <component>   TYPE LINE OF abap_component_tab,
    <range_tab>   TYPE STANDARD TABLE,
    <tab>         TYPE table.
* build dynamic table
  DO 10000 TIMES.
    APPEND INITIAL LINE TO lt_components ASSIGNING <component>.
    <component>-type ?= cl_abap_datadescr=>describe_by_data( lv_lifnr ).
    lv_numc7 = sy-index.
    CONCATENATE 'FIELD' lv_numc7 INTO <component>-name.
  ENDDO.
  lo_struc_descr    ?= cl_abap_structdescr=>create( lt_components ).
  lo_tdescr        = cl_abap_tabledescr=>create( lo_struc_descr ).
  CREATE DATA lr_tab TYPE HANDLE lo_tdescr.
  ASSIGN lr_tab->* TO <tab>.
  APPEND INITIAL LINE TO <tab>.
I discovered that it takes some time (15 seconds or more) to create, even F1 and F4 in the SALV table use considerable time to pop up, I think (SAP never imagined
But it works - and the code is so simple!
Kind regards,
Clemens

Similar Messages

  • How to display more than 60 columns in a report

    I have a table defined as follows
    id
    column_name
    column_value
    data sample
    id col_name column_value
    1 col1 val1
    1 col2 val2
    1 col3 val3
    2 col1 val1
    2 col2 val2
    2 col3 val3
    now I want to display the data in a report as follows
    id col1 col2 col3
    1 val1 val2 val3
    2 val1 val2 val3
    I was able to generate output using pivots [http://technology.amis.nl/blog/1197/pivot-dynamic-data]
    the problem is that I can have more that 60 columns retrieved in each row, the pivot solution will retrieve them correctly but I can't display more than 60 columns in apex reports, why this restriction in apex, any solution

    Hello:
    In the Source section of the report definition choose 'Use Generic Column Names (parse query at runtime only)' and then specify a suitable value for 'Maximum number of generic report columns:'
    Varad

  • Displaying more than one column in TreeControl

    Hi,
    I have three tables ( LaborOperation, LaborIndex, LaborData). In TreeControl, i am displaying the following table columns,
    LaborOperation ->operationid,
    LaborIndex -> indexid,
    LaborData -> date, value.
    i want to be like this.
    + Operation Id(Single Column)
    + OperationIndex(Single Column)
    -OperationData(Multiple Column)
    I can able to display single column values in tree control by setting the nodedifinition property in tree control. i can't able to display more than one column in tree control.
    any idea about this problem
    thanks in advance.
    -Nainar

    Arun Prasath wrote:
    I want to display more than one row in a multiple columns of a single row.
    For example,
    In oracle apps, there are multiple tax lines for a single invoice. Each tax lines having their own entry in tax detail table.
    When i try to display a single invoice's details in a single row i found the difficulty.Hmm did you see the title of the forum? Oracle Database » General Questions !
    May be you want to check the Oracle Apps forum?
    Aman....

  • How to display more than one column with for each

    Hi guys,
    how to display more than one column with for each like below?
    for each
    Item1
    Item2
    Item3
    Item4
    Item5
    Item6
    Item7
    Item8
    Item9
    Item10
    End for each
    for each          
    Item1     Item2     Item3
    Item4     Item5     Item6
    Item7     Item8     Item9
    Item10          
    End for each

    Take a look at this to see if the solution provided would work for you: https://blogs.oracle.com/xmlpublisher/entry/multi_column_row_woes
    Won't you have more than 10 records in your data file ? If you are going to have only 10 items then you may be able to use position() function to limit it to 3 each..
    Take a look at this: https://blogs.oracle.com/xmlpublisher/entry/turning_rows_into_columns
    Thanks,
    Bipuser

  • Ipad - Display more than 8 columns in OWL

    Hi All,
    Currently iPad player will only display the first six columns of the OWL in portrait mode and the first eight columns in landscape mode. Can we display more than 8 column(s) in the OWL either in Potrait or Landscape mode ?
    Thanks,
    Rajesh Nimmakayala

    I really doubt this is possible. This is just how the player renders it out.
    Sorry!
    Fernando

  • How to create combobox to display more than one columns

    I need kind help with the following question. As the combobox includes two pieces--textbox and the combobox list. Then how to create a combo box bean, which is based on table EMP(empno number(6), ename varchar2(40)) records for example, to achieve these features:
    1) allow more than one columns to be displayed in its records list--e.g., I need to show these records:
    empno (value) ename (label)
    103 David M Baker
    104 David M Baker
    105 Kelly J Volpe
    106 Krista F Carpenter
    107 Michelle P Silverman
    The two 'David M Baker's are different employees, but unfortunately, with the same name.
    2) allow combo box list to return the column value 'empno' even though it shows both columns as above. i.e., if user picks the second record above, then the combobox list returns 104 to the textbox in the background, but the 'David M Baker' is displayed on the textbox. Of course the combobox list may return 'David M Baker' if needed when there is only one column in the list as the current standard feature.
    3)allow partial match search by typing in some letters. i.e., if user types in the textbox of the combobox letter 'K' or 'k' then the partially matched records
    105 Kelly J Volpe
    106 Krista F Carpenter
    should be automatically displayed in the combobox list, not the whole list as above; then user may double click to choose one of the two or if user continues to type in 'R' or 'r', then the uniquely matched record 'Krista F Carpenter' is displayed in the textbox and the 106 is returned to the textbox.
    4) as a bonus if it's doable, allow combobox to return values to different textboxes when its records list has more than one columns.
    The reason I need these features is that I am working on the project migrated from Microsoft Access applications to centralized Java version web application. We at beginning promised to users community that Java swing will provide all the GUI user friendly features Microsoft Access has, but now we got stucked--we ate our words and got tons of complains from our users community. This is just the most needed component I posted here. I really hope that Java would add all the default GUI user-friendly features to compete with MS since its Win95 GUI has been accepted as industry standard. And most users are used to it. They claimed that they don't know and don't care what tool you use the newly created application should be more user friendly, not the opposite.
    I would be very much appreciated if any one would help me with this item.

    Thanks for your comments. I think nobody expects Sun to write everything including special features for its components. But I do think Sun should provide at least those standard user-friendly features for the GUI components because most users have been used to the GUI user-friendly features provided by Win95 and Access/Excel applications. Then this will help us to productively create applications to beat MS applications.
    Other wise like me, to get the existing GUI features, existed in old MS Access application, for our migrated Java application, I must re-create the GUI components library first which is a big burden to me at least, for others it might be fun for coding on their own from scratch, but I have to focus on the timing of project.
    If you really can pass the request to Sun and push them move a bit, please pass these words: before Sun starts to revise them, please play around window GUI, e.g., Access/Excel applications, then plan what to do, the bottom line is to equally match or better than them in FUNCTIONALITY(Look and feel is not my focus here). Don't ignore the influence of Windows regardless of you hate it or love it, the reality is most users are so familiar with windows GUI features which are accepted as industry standard. Thus the choice is to match or better to beat them. Don't make your car by closing your door, don't assume users will like what you come out in a closed room.

  • Display more than 255 charecters in alv grid

    Hi,
    I am trying to display the more than 255 harvesters in alv grid(Editable alv). But it is accepting 255 characters only. actually my string length is 2048 (file path).   
    How to display the more than 255 characters sting in alv grid. If any one know this please provide that logic.

    Hi,
    Check this also
    REUSE_ALV_GRID_DISPLAY maximum length
    Re: how to display the data in the alv layout more than 255 characters

  • How to display more than 30 columns in one line?

    Hi,
    I want to display some 30 columns in the report.
    I dont want to split it into sub reports.
    How can i do.
    In that i have 3 groups.
    For each group i need one total.
    For example.
    after group 3 i need sub-total
    after group 2 i need total
    after group 1 i need Grand-total.
    Please help me to solve this issue.
    Thanks in advance,
    Saravanakumar.

    Sorry about that,
    Ill tell you clearly.
    Actualy I am having 12 columns, under each column, i have 5 sub-columns.
    I couldn't accomodate all the columns in a single horizontal line(I tried in A2 paper size).
    So i decided to have cross tab. Because top 5 columns can be dinamic.
    How can have subtotals inside cross tab after each group.
    Thanks ,
    Saravanakumar

  • More then 90 Columns in ALV

    Hi.
    In ALV i want to add more then 90 Columns.
    is their any method to display more then 90 columns in ALV?

    HI,
    ALV is Application List viewer. Sap provides a set of ALV (ABAP LIST VIEWER) function modules which can be put into use to embellish the output of a report. This set of ALV functions is used to enhance the readability and functionality of any report output. Cases arise in sap when the output of a report contains columns extending more than 255 characters in length. In such cases, this set of ALV functions can help choose selected columns and arrange the different columns from a report output and also save different variants for report display. This is a very efficient tool for dynamically sorting and arranging the columns from a report output. The report output can contain up to 90 columns in the display with the wide array of display options.
    advantages.
    Collapse multiple reports into one, drastically cutting down your report development time
    Save many hours using built-in ALV sorting, subtotaling and filtering capabilities
    Add conditional structures into your ALV report: No programming required!
    Combine ALV with display variants to meet a wide range of reporting requirements more easily
    Dynamically reorder column layouts and add/subtract fields
    Enable users and analysts to save their own personalized variants
    The keyword is flexibility. In the past I have sometimes programmed more programs that was basically the same report with minor variations - in one case i programmed 10 very similar reports for pp evaluation.
    With ALV the users can define their own display variants without changing the program.
    The display variant covers sorting, summarizing, filtering, hiding fields. The users can also make variants that show only total lines or subtotal lines or both - and by one click in the report they can expand one total line to display the underlying item lines.
    The users can also choose to let the report show directly in excel. This is a very powerful option. You can upload excel templates with predefined formulas and macros. This can make you very popular - especially with Finance people that already have a lot of excel files, they populate with SAP data to make al kind of voodoo calculations that will help them see into the future.
    With ALV you can give them an ABAP report that automatic popup with their own favorite excel book - without having to do a lot of troublesome and time consuming work to download the data and fit it into the excel sheet.
    If you are new to ALV you can very quick make a simple ALV report. Basically it has 3 steps.
    1) build an internal table with the data you want do display
    2) build a field catalog table (each record in this table describes one column in the list)
    3) call the ALV function
    Later you can make use of more complicated functions like call back routines.
    You have both functions modules and ABAP OO classes to help you with step 2 and 3. I have used the function modules for many years so its hard for me to change, but if I should start all over today I would forget about the function modules and go for the OO approach.
    Thanks,
    Sankar M

  • Want to display more than 300 charcters in a column using ALV grid display

    Hi Guru's,
    I am trying to display more than 500 charcters in a column using alv grid display but it in the output it is showing only 128 characters. Can you help me to display all the characters in particular column Or is there any limitation in maximum of no of charcters for a column?
    Thanks,
    Radha.

    Hi Paurl,
    Define a work area say
    wa_layout type slis_layout_alv.
    then fill this work area as
    wa_layout-zebra = X
    wa_layout-colwidth_optimize = X.
    wa_layout-max_linesize = 300.
    Then in FM 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
    is_layout = wa_layout
    etc.
    you provided this for the field which is displayed in alv grid will have more than 128 characters.
    from this code i want,how it refers to particular field.
    when i mentioned field catalog-OUTPUTLEN = '300'.
    it is not displayed the field morethan 128 characters.
    it only displays 128 characters.
    please provide me clear and breif information with suitable code.
    i am trying what your sending but it is not displayed more than 128 characters.
    if you don't mind please spend for me some time for this and
    give me clear and breif information with suitable code.
    Thanks & Regards,
    Radhakrishna.

  • To display text field with more than 1000 length in ALV

    Hi Friends,
           I need to display material long text field which is more than 1000 length in ALV or Object oriented ALV.
    Please help me to resolve the issue.
    Regards,
    Jaya.

    Hi,
    U mean to say in a single cell of ALV ??
    It is not possible in ALV .. As per OSS note 857823
    Below is the reason for same.. I think you should to split in number of columns.
    Summary
    Symptom
    Entries in cells of the type CHAR or string are truncated after 128 characters in the SAP GUI.
    Other terms
    ALV Grid Control (cl_gui_alv_grid), function module (Full-screen)
    Grid (Reuse_alv_grid_display, SAPLSLVC_FULLSCREEN), SAPGUI, back end, front end
    Reason and Prerequisites
    The data table that is sent to the front end only allows character values with the length 128.
    Solution
    This is the standard system behavior and cannot be changed.

  • How to display more than 255 chars in background job with ALV Grid ????

    Hi All,
    I am using ALV grid with OO.
    I have used call screen for ALV grid display. I have to display more than 255 characters in width. While running it, I can see the list perfectly.
    But in background mode, the list is truncated after 255 chars.
    Can anybody help how to send complete list(width more than 255 chars) to spool.
    Thanks and Regards,
    Neha

    Hi SAP fan,
    <b>YES you can run the ALV report in background mode.
    To run the report in background do F9 instead of F8, then give immediate and save.
    Now goto Sm35 goto job overview and view the job listed
    Choose the job and press the spool button. It will show the list created on the next page. When u clcik the list u can see the ALV output.
    To see this the job should be in the finished status.
    How to define Periodic Jobs
    1.Execute transaction SM36
    2.Define Job name, Job class, Target server
    3.Click on 'START CONDITION' button
    4.Click on 'Date/Time' button
    5.Enter Scheduled start DATE & TIME. Check mark 'Periodic Job' field. Click on 'Period values' button and select 'Hourly' or 'Dialy' or 'Weekly' or 'Monthly' or Other period and SAVE. Go back to main screen.
    6.Click on 'STEPS' button and enter Program name and Variant under box 'ABAP Program'. Click on 'Print Specification' button and enter Printer name under 'Output device' and SAVE
    7.Click on SAVE button until you get message on bottom of the screen that describes 'Job XYZ saved with status: Scheduled'.
    8.Click on 'Job overview' button or execute SM37 transaction.
    9.Select the appropriate 'Job name', 'User name', 'Job Status' & Schedule date under 'Job start condition' and click on 'Execute' button or press F8.
    10.You will now see all your scheduled JOBS.
    <b>Case: 2</b>
    You can Run in Background but make sure it is alv list, not alv Grid FM. if you are uisng alv list not problem , but if you are using alv grid then you can code like this..
    if sy-batch = ' '.
    call 'REUSE_ALV_GRID_DISPLAY'.
    else.
    call 'REUSE_ALV_LIST_DISPLAY'.
    endif.
    if you are using OO alv then write this code..
    CALL METHOD cl_gui_alv_grid=>offline
                    RECEIVING e_offline = off.
        IF off IS INITIAL.
          CREATE OBJECT g_custom_container
                 EXPORTING container_name = g_container.
        ENDIF.
    <b>Case: 3</b>
    if you are using OO ALV.
    Just before creating the custom container check for the following condition.
    Batch or Web Reporting
    IF cl_gui_alv_grid=>offline( ) IS INITIAL.
    CREATE OBJECT o_custcontainer
    EXPORTING
    container_name = lc_custcontrol
    EXCEPTIONS
    cntl_error = 1
    cntl_system_error = 2
    create_error = 3
    lifetime_error = 4
    lifetime_dynpro_dynpro_link = 5
    OTHERS = 6
    ENDIF.
    You can see the output in Spool in transaction SP01.</b>
    Good Luck and thanks
    AK

  • ALV to select more than one column by row using set_table_for_first_display

    Hello everyone,
    I am developing an application (ALV OO) to select more than 1 column by row ( one ). This is an a holiday application so the idea is:
    -One column will be the day, and the row will be the user.
    So I am trying to select more than one day by user (that would be the row).
    I am using the method set_table_for_first_display but when it shows the alv, doesn't let me to select more than one column with a click of the mouse.
    Does anybody know if I can do this (select more than one column, by row) in somehow?
    Please let me know if you need more clarification about this.
    Thanks in advance
    Diego

    Hi Diego,
    it's all in the documentation.
    set different selection modes through the value of the field u201CSEL_MODEu201D in the layout structure.
    SPACE
    same as 'B'
    see 'B'
    Default setting
    'A'
    Column and row selection
    Multiple columns
    Multiple rows
    The user selects the rows through pushbuttons at the left border of the grid control.
    'B'
    Simple selection, list box
    Multiple columns
    Multiple rows
    'C'
    Multiple selection, list box
    Multiple columns
    Multiple rows
    'D'
    Cell selection
    Multiple columns
    Multiple rows
    Any cells
    The user selects the rows through pushbuttons at the left border of the grid control
    Beyond setting this option, you can set u201CNO_ROWMARKu201D option to hide the mark column which is normally visible when the selection mode allows multiple row selection.
    One point to notice here is that if you set your ALV Grid as to be editable, it may override your selection mode regardless of your layout settings.
    This is from SDN Community Contribution "An Easy Reference for ALV Grid Control" By: Serdar ŞİMŞEKLER
    Sorry, no link,. it's on my disk.
    Regards,
    Clemens

  • Hotspot on more than one fields in ALV Report

    I want to add Hotspot on more than one field in ALV,
      one field is Vbeln , one is BSTNK, one is matnr and so on.
    i have used form user_command.and have written coding for Vbeln (on vbeln i am showing transaction VA02)
    i want to pass an eror mesaage when user clicks on bstnk or matnr.
    Thanks

    Hi Lovleen,
    *Global definitions  *
    Data Types
    type-pools: slis.
    types: begin of tp_data,
    ebeln like ekko-ebeln,
    *matnr like ekko-matnr,
    *meins like ekko-meins,
    lifnr like lfa1-lifnr,
    chk1,
           end of tp_data,
           tp_tbl_data type standard table of tp_data.
    Constants
    Data objects (variable declarations and definitions)
    Report data to be shown.
    data: it_data type standard table of tp_data.
    Heading of the report.
    data: t_heading type slis_t_listheader.
    ======================= Selection Screen ==========================
    selection-screen: begin of block b1 with frame title text-t01.
    DATA: w_aux_ebeln like ekko-ebeln.
    SELECT-OPTIONS s_ebeln for w_aux_ebeln
    DEFAULT 1000 .
    DATA: w_aux_lifnr like lfa1-lifnr.
    SELECT-OPTIONS s_lifnr for w_aux_lifnr
    DEFAULT 00000001000 .
    selection-screen: end of block b1.
    ======================== Event Blocks =============================
    at selection-screen.
    start-of-selection.
      perform get_data using it_data.
    end-of-selection.
      perform build_alv using it_data t_heading.
    ======================== Subroutines ==============================
    *&      Form  get_data
          Gets the information to be shown in the report.
    form get_data using t_data type tp_tbl_data.
    SELECT e~ebeln
    *e~matnr
    *e~meins
    l~lifnr
    INTO CORRESPONDING FIELDS OF TABLE t_data
    FROM ekko as e
    inner join lfa1 as l on elifnr = llifnr
    WHERE e~ebeln in s_ebeln
    AND l~lifnr in s_lifnr
    endform.                    " get_data
    *&      Form  build_alv
          Builds and display the ALV Grid.
    form build_alv using t_data type tp_tbl_data
                         t_heading  type slis_t_listheader.
    ALV required data objects.
    data: w_title   type lvc_title,
          w_repid   type syrepid,
          w_comm    type slis_formname,
          w_status  type slis_formname,
          x_layout  type slis_layout_alv,
          t_event    type slis_t_event,
          t_fieldcat type slis_t_fieldcat_alv,
          t_sort     type slis_t_sortinfo_alv.
    refresh t_fieldcat.
    refresh t_event.
    refresh t_sort.
    clear x_layout.
    clear w_title.
    Field Catalog
      perform set_fieldcat2 using:
    1 'CHK1' 'XFELD' space space space 'Select' 'Select this row' 'Sel'
    'Select this row' space space space 'X' 'X' space t_fieldcat,
    2 'EBELN' 'EBELN' 'EKKO' space space  space  space  space  space space
    space space space space space t_fieldcat ,
    3 'MATNR' 'MATNR' 'EKKO' space space  space  space  space  space space
    space space space space space t_fieldcat ,
    4 'MEINS' 'MEINS' 'EKKO' space space  space  space  space  space space
    space space space space space t_fieldcat ,
    5 'LIFNR' 'LIFNR' 'LFA1' space space  space  space  space  space space
    space space space space space t_fieldcat .
    Layout
    x_layout-zebra = 'X'.
    Top of page heading
      perform set_top_page_heading using t_heading t_event.
    Events
      perform set_events using t_event.
    GUI Status
      w_status = ''.
      w_repid = sy-repid.
    Title
    w_title = <<If you want to set a title for
                the ALV, please, uncomment and edit this line>>.
    User commands
      w_comm   = 'USER_COMMAND'.
    Order
    Example
    PERFORM set_order USING '<field>' 'IT_DATA' 'X' space space t_sort.
    Displays the ALV grid
      call function 'REUSE_ALV_GRID_DISPLAY'
        exporting
          i_callback_program       = w_repid
          it_fieldcat              = t_fieldcat
          is_layout                = x_layout
          it_sort                  = t_sort
          i_callback_pf_status_set = w_status
          i_callback_user_command  = w_comm
          i_save                   = 'X'
          it_events                = t_event
          i_grid_title             = w_title
        tables
          t_outtab                 = t_data
        exceptions
          program_error            = 1
          others                   = 2.
      if sy-subrc <> 0.
        message id sy-msgid type sy-msgty number sy-msgno
                with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      endif.
    endform.                    " build_alv.
    *&      Form  set_top_page_heading
          Creates the report headings.
    form set_top_page_heading using t_heading type slis_t_listheader
                                    t_events  type slis_t_event.
    data: x_heading type slis_listheader,
          x_event   type line of slis_t_event.
    Report title
      clear t_heading[].
      clear x_heading.
      x_heading-typ = 'H'.
      x_heading-info = ''(001).
      append x_heading to t_heading.
    Program name
      clear x_heading.
      x_heading-typ = 'S'.
      x_heading-key = 'Program: '.
      x_heading-info = sy-repid.
      append x_heading to t_heading.
    User who is running the report
      clear x_heading.
      x_heading-typ = 'S'.
      x_heading-key = 'User: '.
      x_heading-info = sy-uname.
      append x_heading to t_heading.
    Date of execution
      clear x_heading.
      x_heading-typ = 'S'.
      x_heading-key = 'Date: '.
      write sy-datum to x_heading-info.
      append x_heading to t_heading.
    Time of execution
      clear x_heading.
      x_heading-typ = 'S'.
      x_heading-key = 'Time: '.
      write sy-uzeit to x_heading-info.
      append x_heading to t_heading.
    Top of page event
      x_event-name = slis_ev_top_of_page.
      x_event-form = 'TOP_OF_PAGE'.
      append x_event to t_events.
    endform.
    *&      Form  set_events
          Sets the events for ALV.
          The TOP_OF_PAGE event is alredy being registered in
          the set_top_page_heading subroutine.
    form set_events using t_events type slis_t_event.
    data: x_event   type line of slis_t_event.
    Example
    clear x_event.
    x_event-name = .
    x_event-form = .
    append x_event to t_event.
    endform.
    *&      Form  set_order
          Adds an entry to the order table.
    FORM set_order USING p_fieldname p_tabname p_up p_down p_subtot
                         t_sort TYPE slis_t_sortinfo_alv.
      DATA: x_sort TYPE slis_sortinfo_alv.
      CLEAR x_sort.
      x_sort-fieldname = p_fieldname.
      x_sort-tabname   = p_tabname.
      x_sort-up = p_up.
      x_sort-down = p_down.
      x_sort-subtot = p_subtot.
      APPEND x_sort TO t_sort.
    ENDFORM.                    "set_order
    *&      Form  set_fieldcat2
          Adds an entry to the field catalog.
       p_colpos: Column position.
       p_fieldname: Field of internal table which is being described by
    *            this record of the field catalog.
       p_ref_fieldname: (Optional) Table field / data element which
    *                describes the properties of the field.
    *                If this field is not given, it is copied from
    *                the fieldname.
       p_ref_tabname: (Optional) Table which holds the field referenced
    *              by <<p_ref_fieldname>>.
                      If this is not given, the parameter
                      <<p_ref_fieldname>> references a data element.
       p_outputlen: (Optional) Column width.
       p_noout: (Optional) If set to 'X', states that the field is not
    *           showed initially. If so, the field has to be
                included in the report at runtime using the display
                options.
       p_seltext_m: (Optional) Medium label to be used as column header.
       p_seltext_l: (Optional) Long label to be used as column header.
       p_seltext_s: (Optional) Small label to be used as column header.
       p_reptext_ddic: (Optional) Extra small (heading) label to be
    *                used as column header.
       p_ddictxt: (Optional) Set to 'L', 'M', 'S' or 'R' to select
                  whether to use SELTEXT_L, SELTEXT_M, SELTEXT_S,
                  or REPTEXT_DDIC as text for column header.
       p_hotspot: (Optional) If set to 'X', this field will be used
    *             as a hotspot area for cursor, alolowing the user
    *          to click on the field.
       p_showasicon: (Optional) If set to 'X', this field will be shown
                     as an icon and the contents of the field will set
    *             which icon to show.
       p_checkbox: (Optional) If set to 'X', this field will be shown
                   as a checkbox.
       p_edit: (Optional) If set to 'X', this field will be editable.
       p_dosum: (Optional) If set to 'X', this field will be summed
                (aggregation function) according to the grouping set
                by the order functions.
       t_fieldcat: Table which contains the whole fieldcat.
    FORM set_fieldcat2 USING
          p_colpos p_fieldname p_ref_fieldname p_ref_tabname
          p_outputlen p_noout
          p_seltext_m p_seltext_l p_seltext_s p_reptext_ddic p_ddictxt
          p_hotspot p_showasicon p_checkbox p_edit
          p_dosum
          t_fieldcat TYPE slis_t_fieldcat_alv.
      DATA: wa_fieldcat TYPE slis_fieldcat_alv.
      CLEAR wa_fieldcat.
    General settings
      wa_fieldcat-fieldname = p_fieldname.
      wa_fieldcat-col_pos = p_colpos.
      wa_fieldcat-no_out = p_noout.
      wa_fieldcat-hotspot = p_hotspot.
      wa_fieldcat-checkbox = p_checkbox.
      wa_fieldcat-icon = p_showasicon.
      wa_fieldcat-do_sum = p_dosum.
    Set reference fieldname, tablenam and rollname.
    If p_ref_tabname is not given, the ref_fieldname given
       is a data element.
    If p_ref_tabname is given, the ref_fieldname given is a
       field of a table.
    In case ref_fieldname is not given,
       it is copied from the fieldname.
      IF p_ref_tabname IS INITIAL.
        wa_fieldcat-rollname =   p_ref_fieldname.
      ELSE.
        wa_fieldcat-ref_tabname = p_ref_tabname.
        IF p_ref_fieldname EQ space.
          wa_fieldcat-ref_fieldname =   wa_fieldcat-fieldname.
        ELSE.
          wa_fieldcat-ref_fieldname =   p_ref_fieldname.
        ENDIF.
      ENDIF.
    Set output length.
      IF NOT p_outputlen IS INITIAL.
        wa_fieldcat-outputlen = p_outputlen.
      ENDIF.
    Set text headers.
      IF NOT p_seltext_m IS INITIAL.
        wa_fieldcat-seltext_m = p_seltext_m.
      ENDIF.
      IF NOT p_seltext_l IS INITIAL.
        wa_fieldcat-seltext_l = p_seltext_l.
      ENDIF.
      IF NOT p_seltext_s IS INITIAL.
        wa_fieldcat-seltext_s = p_seltext_s.
      ENDIF.
      IF NOT p_reptext_ddic IS INITIAL.
        wa_fieldcat-reptext_ddic = p_reptext_ddic.
      ENDIF.
      IF NOT p_ddictxt IS INITIAL.
        wa_fieldcat-ddictxt = p_ddictxt.
      ENDIF.
    Set as editable or not.
      IF NOT p_edit IS INITIAL.
        wa_fieldcat-input     = 'X'.
        wa_fieldcat-edit     = 'X'.
      ENDIF.
      APPEND wa_fieldcat TO t_fieldcat.
    ENDFORM.                   "set_fieldcat2
    ======================== Subroutines called by ALV ================
    *&      Form  top_of_page
          Called on top_of_page ALV event.
          Prints the heading.
    form top_of_page.
      call function 'REUSE_ALV_COMMENTARY_WRITE'
        exporting
        i_logo             = <<If you want to set a logo, please,
                             uncomment and edit this line>>
          it_list_commentary = t_heading.
    endform.                    " alv_top_of_page
    *&      Form  user_command
          Called on user_command ALV event.
          Executes custom commands.
    form user_command using r_ucomm     like sy-ucomm
                            rs_selfield type slis_selfield.
    Example Code
    Executes a command considering the sy-ucomm.
    CASE r_ucomm.
       WHEN '&IC1'.
         Set your "double click action" response here.
         Example code: Create and display a status message.
         DATA: w_msg TYPE string,
               w_row(4) TYPE n.
         w_row = rs_selfield-tabindex.
         CONCATENATE 'You have clicked row' w_row
                     'field' rs_selfield-fieldname
                     'with value' rs_selfield-value
                     INTO w_msg SEPARATED BY space.
         MESSAGE w_msg TYPE 'S'.
    ENDCASE.
    End of example code.
    endform.                    "user_command
    Reward Points if useful.
    Regards,
    Manoj Kumar

  • ABAP Programming to display more than 255 characters in the screen

    Hi
       I want to display more than 255 characters in the screen after executing a report but i cant able to do that.
    Please help me to find out the solution.
    Thanks
      Mrutyunjaya Trpathy

    Hai tripathy,
    when the output of a report contains columns extending more than 255 characters in length.  In such cases, this set of ALV functions can help choose selected columns and arrange the different columns from a report output and also save different variants for report display. This is a very efficient tool for dynamically sorting and arranging the columns from a report output. The report output can contain upto 90 columns in the display with the wide array of display options.
    The commonly used ALV functions used for this purpose are;
    1.REUSE_ALV_VARIANT_DEFAULT_GET
    2.REUSE_ALV_VARIANT_F4
    3.REUSE_ALV_VARIANT_EXISTENCE
    4.REUSE_ALV_EVENTS_GET
    5.REUSE_ALV_COMMENTARY_WRITE
    6.REUSE_ALV_FIELDCATALOG_MERGE
    7.REUSE_ALV_LIST_DISPLAY
    8.REUSE_ALV_GRID_DISPLAY
    9.REUSE_ALV_POPUP_TO_SELECT
      hope u can try in this way.
    REGARDS,
    PRABA.

Maybe you are looking for

  • Officejet Pro 8600 Plus copy prints with black streaks

    I just bought an HP Officejet Pro 8600 Plus and it seems to work great at printing; however, when I tried to copy something, the copy came out with black streaks that nearly render the print illegible and are the most dark/condensed towards the left

  • Oracle 8.1.7 on 6.2 RedHat installation

    Hello, Well, everything is running fine except, it would seem for the java stuff. Things where working great yesterday, but today, for no appearent reason that I can tell, all of my java related management apps now cease to function. I get SIGSEGV at

  • Preview in Search Results

    Hi all, when I get the Result List after a Search in TREX 6.1, I can see preview of the (I think) first lines which are included in the document - Does anybody know, if it's possible to change that, so that there will not be shown the first lines of

  • Why can't I send a mail from an iPhoto Album in Safari

    After uploading an album from iPhoto I open the gallery in Safari 3.2.1. Then I get the option of sending a mail under "Tell a friend". I enter my mailadress and the addressees' mailaddress and then I try to enter the scrambled letters in the designa

  • 6602 Multiple Counter Output

    Hi I would like to output a counter signal on all eight of my outputs on the PCI6602.  These outputs have to be able to be stopped individually.  How do I do this in labview 8.