ALV report : to display description in two lines.

Hi all,
In a ALV grid display,  I want to print description(40 characters) of a field in two lines(20 characters in each).
Please suggest me how to achive the same.
Thanks in advance.

make the description field of 20 char legth in your final internal table.
while passing data to your final internal table, pass all fields along with 20chars from description to one line of final table and in the same loop add another row with all fields blank but the description with rest of the fields..
loop at it_1 into it_s.
is_final-desc = it_s-desc+0(20).
apppend is_fianl to it_final.
clear is_final.
is_fianl-desc = it_1-desc+20(20).
apppend is_fianl to it_final.
clear it_s.
endloop.

Similar Messages

  • Displaying data in Two line in ALV report

    Hi,
    I want to know how to display the data in alv in two lines for Fild name as well as for fild value
    like in below case
    wa_fieldcata-fieldname  = 'WRBTR'.
       wa_fieldcata-seltext_l  = 'AMOUNT IN DOCUMENT CURRENCY'.
       wa_fieldcata-outputlen  = 18.
       wa_fieldcata-DO_SUM     = 'X'.
       APPEND wa_fieldcata TO it_fieldcat.
       CLEAR wa_fieldcata.
    by this on alv COLUMN headig is coming as 'AMOUNT IN DOCUMENT CURRENCY' in one linw  i want to display  'AMOUNT IN '   in first line and then 'DOCUMENT CURRENCY' below that
    'AMOUNT IN
    DOCUMENT CURRENCY' ***
    similarly how to display value of three fidls in one column
    like for a vendor   I have one column  Vandor name in that column i want to display from table LFA1, 
    NAME1
    NAME2
    NAME3
    NAME4,
    in one column only how to do it.
    regards,
    zafar

    Hi,
    Ref . early reply  can u help me how to uset his in ALV code  and can u give some example for this  how to display it in two lines  as my column heading is of 60 characters 5 word i want to display it in two line in one column only  .
    How to use : SLIS_EV_AFTER_LINE_OUTPUT
    to get this.
    or is there any other method.
    regards,
      zafar

  • SAP Script : to display the material description in two lines

    Hi All,
    I'm working on scripts.
    the material description field is been passed from my driver program ..into the script..
    Ex: &gs_final-maktx& ..
    There r a number of other fields to be displayed ...after this field ....
    Is there any option to split the 'Material description into two lines'?
    Ex: at present it is :
    This is material description
    Requirement is:
    This is material
    description
    I mean that there a number of field berfore and after this field......in the same line
    I need to jst split the materia description ...& make it to appear in two lines.....!!
    Expecting your suggestions....
    Edited by: vidya vidya on Nov 11, 2008 3:17 PM
    Edited by: vidya vidya on Nov 11, 2008 3:20 PM

    FM TEXT_SPLIT ?
    ..but i handled this by code.
    DATA:      zzboldsx(18) TYPE c,
          zzboldsx2(18) TYPE c,
          zzboldsx3(18) TYPE c,
          zzboldsx4(18) TYPE c.
    DATA: i_lines TYPE STANDARD TABLE OF tline WITH HEADER LINE ,
            r_lines TYPE tline,
            v_cnt LIKE sy-tabix.
    CALL FUNCTION 'READ_TEXT'
        EXPORTING
          client                  = sy-mandt
          id                      = stxh-tdid
          language                = stxh-tdspras
          name                    = name
          object                  = stxh-tdobject
        TABLES
          lines                   = i_lines[]
        EXCEPTIONS
          id                      = 1
          language                = 2
          name                    = 3
          not_found               = 4
          object                  = 5
          reference_check         = 6
          wrong_access_to_archive = 7
          OTHERS                  = 8.
      IF sy-subrc = 0.
    * Only 4 lines of Header text supported. Can add if needed
        LOOP AT i_lines INTO r_lines.
          CONDENSE r_lines-tdline NO-GAPS.
          v_cnt = v_cnt + 1.
          CASE v_cnt.
            WHEN 1.
              zzboldsx = r_lines-tdline.
            WHEN 2.
              zzboldsx2 = r_lines-tdline.
            WHEN 3.
              zzboldsx3 = r_lines-tdline.
            WHEN 4.
              zzboldsx4 = r_lines-tdline.
            WHEN OTHERS.
              EXIT.
          ENDCASE.
    *   zzbolDSX =  i_lines-tdline .
        ENDLOOP.

  • In ALV to make coloum heading in two lines

    I have requrement that my alv report should display the output in two lines.
    ie the first one should be in English and the second line should be in fresh for the same field description .
    Is this posible? can one help me in doing this.

    Hi,
      I guess this is not possible to display the report header in two lines.
    If you find any solution then please post it in SDN, so that i can use the functionality in my future.
    Rgds,
    Bujji

  • Taking download into excel from ALV Grid - header is printing in two lines

    Hi All,
    I have a scenario where I am taking the download from ALV grid to an excel sheet. Now the header of the ALV (column names) is appearing in two lines in the downloaded excel sheet while items (records of the ALV table) are getting displayed in a single line.
    This download is taken from the standard download to local file (spreadsheet) button provided by SAP for ALVs.
    I am using function module "Reuse_alv_grid_display" for the purpose.
    Can somebody provide an idea how I can avoid the header printing in two lines and keep the length as it is.
    Thanks in Advance,
    Chandan

    Hi..
    1. Pass header name in internal table appned first line.
    2. after that pass u r data .
    3. Use  FM. WS_DOWNLOAD 
    Salil ......
    Edited by: salil chavan on Nov 26, 2008 11:07 AM

  • Parameter description in two lines

    hi All,
    i need to have a big description for one of the parameter.
    how can i have the description in two line for the same parameter.
    I have use Coment statement for the parameter.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (45) text-002 FOR FIELD p_devatn.
    PARAMETER:  p_devatn(13) TYPE c DEFAULT '0.01'.
    SELECTION-SCREEN END OF LINE.
    kindly  suggest me a way to get the description in two lines.
      Description of parameter             input filed of the parameter
      This is paramerter for                  
      value range
    many thanks,
    Anuj.
    Edited by: Anuj112143 on Nov 24, 2010 4:33 AM

    Hello Anuj ,
      I dont think you can have the description of the parameter  on 2 lines , may be what you can do is to use comment for the 2nd line .
    E.g.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (45) text-001 FOR FIELD p_matnr.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN COMMENT (45) text-002 FOR FIELD p_matnr.
    parameters : p_matnr type mara-matnr.
    SELECTION-SCREEN END OF LINE.
    Regards,
    Arun

  • ALV report which displays Delivery and Invoice details..by linking vbfa.

    Hi...
    I wants to develop an ALV Report, which displays Delivery details as well as Invoice details for a range of given sale orders.
    For this report I am using Tables : VBAK,VBAP,LIKP,LIPS,VBFA tables .
    Here VBFA is a table for Document flow how to link this with report ??
    Please reply.
    Regards ,
    ASHOK
    Moderator message : Not enough re-search before posting, spec dumping not allowed. Thread locked.
    Edited by: Vinod Kumar on Aug 1, 2011 9:58 AM

    VBFA has VBELV and POSNV can be used to map VBAP (sales order item) i.e.
    VBFA-VBELV = VBAP-VBELN AND
    VBFA-POSNV = VBAP-POSNV
    with VBTYP_N = J Values available in VBFA-VBELN and VBFA-POSNN will be LIPS -VBELN and LIPS-POSNR
    VBTYP_N/ VBTYP_V = J stands for delivery and C stands for order
    Nitesh

  • ALV Report to display the status of the requests raised through ESS

    Hi All,
    We have to develop a ALV report to display the status of the requests raised through ESS
    for Leave, Travel & Event Management, Travel and Appraisal workflows.
    ESS Travel, ESS TEM, ESS Apraisal workflows are associted with SAP Business Objects.
    we are using the function module SWI_WORKITEMS_OF_OBJTYPE_GET to get
    the top level work item id's by passing the object type like PDRELA_025, BUS2089.
    By using SWP_WORKFLOW_LOG_READ function we are getting the workflow log
    by passing top level work item id's as imort parameter. 
    The report output should have the following fields
    Initiator, Initiator Personal No, Request Type( Leave, Travel etc.. )
    Date of application of the request, Status ( Approved by RM, Rejected etc )
    Name of the Approver, Approved / Rejected Date.
    The logic should be work for all the above ESS workflows and should be generalized.
    Can any one please let me know the procedure to get the required information from the workflow log.
    It would be great if any one suggest on the same how to proceed further to get the information as mentioned above.
    Thanks & Regards,
    Jagadeeswara Rao Balla.

    Hello,
    You can get most of that information from fm SAP_WAPI_GET_HEADER, input is workitem_id.
    regards
    Rick Bakker
    Hanabi Technology

  • How to devolped an Interactive ALV Report to display sales orders

    hi,
             how to devolped an Interactive ALV Report to display sales orders pertaining to the selected Customers and item details in the secondary list.For this report what are the tables and fields wehave to used give with example.
    thank you
    radhakrishna

    Hi,
    look via se38 for BCALV* and SALV*.
    Try ABAPDOCU.
    Regards, Dieter

  • Field description in two line in ALV report

    Hi ,
    In ALV report I  want the description for each field to be displayed in two lines . For example
    the description for field matnr is " Material No for grade A " which is displayed in one line . But i want to display it as :  Material No
                                                           for grade A
    in two lines . Is it possible . Please help me out .
    Neetesh

    Hi Neetesh,
      Its not possible to display as you like in 2 lines header for single column. But i can provide the alternative way , it won't good logically. Please try the following logic.
    Let suppose you have 10 fields F1-f10. Each field has the 2 lines header. So take 20fields in your fields catalog ie take 10 dummy fields which are equal lenght of the fields F1-f10. and for the last 10 fields(F11-F20) set the row pos as 2, set the second line header to these field(F11-F20). So you will succed to display the 2 level header for single column. But the problem here is you will get one empty row additional row for each row. Because you have taken (F11-F20) fields are dummy and don't have the data also. This solution will works only in the case of ALV List display not in Grid Display.
      But Before that tell to your customer about this problem , Because I have done the same things when my customer giving important to 2 lines header and he accepeted that also.
    If suppose you have the data in 2 lines for each column then this solution will work fine. Thats what i implemented in my ALV Report.
    Warm Regards,
    Vijay.

  • Interactive Reports: Display data on two lines per row?

    Is it somehow possible to display a single row across two lines in an interactive report?
    Something like this:
    Row1 Field 1, Row1 Field 2, Row1 Field 3
    Row1 Field 4 (spanning across the other fields)
    Row2 Field 1, Row2 Field 2, Row2 Field 3
    Row2 Field 4 (spanning across the other fields)
    Row3 Field 1, Row3 Field 2, Row3 Field 3
    Row3 Field 4 (spanning across the other fields)
    ... etc
    For example, I have a "Remarks" column that would look better on its own line, rather than being squeezed into the same row with the other columns.
    I realize that this layout might not be possible out-of-the-box, but I was thinking that perhaps some javascript/jQuery trick could be used. Unfortunately, my jQuery-fu is not strong yet, so I'm asking for help...
    (I also know that this type of layout is possible using a classic report with a custom template, but I would prefer to use the Interactive Report if at all possible.)
    - Morten

    Hi,
    Try this to page HTML header
    <style>
    .apexir_WORKSHEET_DATA td{white-space:nowrap!important;}
    </style>At least it work with firefox 3.5 for me
    Br, Jari

  • Alv report colour display

    hi
    i have a requirment in my alv report ,i need to show values of material description i.e  only gsm values in different colour i. 296 GSM and corresponding below values 285 GSM,.below show is sample output onf my alv report.
    materialno                              material deccription
                              GB CPB HWC 296 GSM 055.000 X 092.000
                              GB CPB HWC 296 GSM 082.000 X 117.000
                              GB CPB HWC 285 GSM 045.200 X 070.500
                              GB CPB HWC 285 GSM 045.200 X 070.500
                              GBCPB HWC 285 GSM 045.200 X 070.500
                              GB CPB HWC 285 GSM 045.200 X 070.500

    Hi
    i am sending you a code where i had colored one field
    you can refer this program and you can understand very well where exactly what we have to do for colors
    reward if usefull
    REPORT zalv_with_colored_fields  .
    TYPE-POOLS : slis.
    DATA : BEGIN OF it_final1 OCCURS 0,
             carrid TYPE spfli-carrid,
             connid TYPE spfli-connid,
             cityfrom TYPE spfli-cityfrom,
             cityto TYPE spfli-cityto,
             cellcolors TYPE lvc_t_scol,
             END OF it_final1 .
    DATA : BEGIN OF it_final OCCURS 0,
             carrid TYPE spfli-carrid,
             connid TYPE spfli-connid,
             cityfrom TYPE spfli-cityfrom,
             cityto TYPE spfli-cityto,
             END OF it_final .
    DATA : git_cellcolors TYPE TABLE OF lvc_s_scol,
           gwa_color    TYPE lvc_s_scol,
           layout       TYPE slis_layout_alv.
    DATA : it_fieldcat TYPE slis_t_fieldcat_alv,
           wa_fieldcat LIKE LINE OF it_fieldcat.
    START-OF-SELECTION .
      SELECT carrid connid cityfrom cityto FROM spfli INTO TABLE it_final .
      wa_fieldcat-col_pos   = '0'.
      wa_fieldcat-tabname   = 'IT_FINAL' .
      wa_fieldcat-fieldname = 'CARRID' .
      wa_fieldcat-seltext_m = 'Carrier ID'(001) .
      APPEND wa_fieldcat TO it_fieldcat .
      wa_fieldcat-col_pos   = '1'.
      wa_fieldcat-tabname   = 'IT_FINAL' .
      wa_fieldcat-fieldname = 'CONNID' .
      wa_fieldcat-seltext_m = 'Flight Connection Number'(002) .
      APPEND wa_fieldcat TO it_fieldcat .
      wa_fieldcat-col_pos   = '2'.
      wa_fieldcat-tabname   = 'IT_FINAL' .
      wa_fieldcat-fieldname = 'CITYFROM' .
      wa_fieldcat-seltext_m = 'City from'(003) .
      APPEND wa_fieldcat TO it_fieldcat .
      wa_fieldcat-col_pos   = '3'.
      wa_fieldcat-tabname   = 'IT_FINAL' .
      wa_fieldcat-fieldname = 'CITYTO' .
      wa_fieldcat-seltext_m = 'City to'(004) .
      APPEND wa_fieldcat TO it_fieldcat .
      LOOP AT it_final .
        it_final1-carrid   = it_final-carrid.
        it_final1-connid   = it_final-connid.
        it_final1-cityfrom = it_final-cityfrom.
        it_final1-cityto   = it_final-cityto.
        CLEAR gwa_color.
      <b>  IF it_final-carrid    = 'AA' .
          gwa_color-fname     = 'CARRID'.
          gwa_color-nokeycol  = '1'.
         gwa_color-color-col = '6'.
          gwa_color-color-int = '1'.</b>
          APPEND gwa_color TO git_cellcolors.
          it_final1-cellcolors = git_cellcolors.
        ENDIF.
        IF it_final-carrid    = 'AZ' .
          gwa_color-fname     = 'CARRID'.
         gwa_color-nokeycol  = '1'.
          gwa_color-color-col = '5'.
          gwa_color-color-int = '1'.
          APPEND gwa_color TO git_cellcolors.
          it_final1-cellcolors = git_cellcolors.
        ENDIF.</b>
        REFRESH git_cellcolors.
        APPEND it_final1.
        CLEAR : it_final , it_final1 .
      ENDLOOP.
      layout-coltab_fieldname = 'CELLCOLORS'.
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
          is_layout   = layout
          it_fieldcat = it_fieldcat
        TABLES
          t_outtab    = it_final1.

  • ALV report to display data based upon radio button.

    i am new to abap, I have a requirement its like there are three radio buttons , r1 r2 r3  If i click r1 datas of r1 should display
    if i click r2 datas of r1 and r2 should display if i click r3 datas of r1 r2 and r3 should display , its ALV report. Please give me solution.

    Hi
    You can use by having the radio buttons in the same group. For ex i'm stating if want to have r radio buttons for change, display and create and you select it with a push button you can code it as ..
    //////SAMPLE CODE
    SELECTION-SCREEN BEGIN OF BLOCK BLOCK1 WITH FRAME TITLE TEXT-003 NO INTERVALS.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS: SRCE RADIOBUTTON GROUP ELE.
    SELECTION-SCREEN COMMENT 3(15) TEXT-004.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS: VARIN RADIOBUTTON GROUP ELE.
    SELECTION-SCREEN COMMENT 3(15) TEXT-005.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS: ATTR RADIOBUTTON GROUP ELE.
    SELECTION-SCREEN COMMENT 3(15) TEXT-006.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS: DOCU RADIOBUTTON GROUP ELE.
    SELECTION-SCREEN COMMENT 3(15) TEXT-007.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS: TXELE RADIOBUTTON GROUP ELE.
    SELECTION-SCREEN COMMENT 3(15) TEXT-008.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN SKIP 1.
    SELECTION-SCREEN BEGIN OF LINE.
    SELECTION-SCREEN PUSHBUTTON 1(15)  TEXT-009 USER-COMMAND DISPL.
    SELECTION-SCREEN PUSHBUTTON 18(15) TEXT-010 USER-COMMAND CHNGE.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN END OF BLOCK BLOCK1.
    *PARAMETERS : XXX LIKE T100A-ARBGB MATCHCODE OBJECT YCL_T100A.
    AT SELECTION-SCREEN.
    CASE SY-UCOMM.
    WHEN 'CREAT'.
      MESSAGE I000(YCL_MC01) WITH 'Create'. // or insert your alv code here
    WHEN 'DISPL'.
      MESSAGE I000(YCL_MC01) WITH 'Display'. // or insert your alv code here
    WHEN 'CHNGE'.
      MESSAGE I000(YCL_MC01) WITH 'Change'. // or insert your alv code here
    ENDCASE.
    //////SAMPLE CODE
    In same you can code it.
    Hope this is useful to you.
    Regards
    Vinodh

  • Update SAP tables after ALV report is displayed

    Hi All,
    I have to display a ALV report using function module REUSE_ALV_GRID_DISPLAY.
    After the report is displayed, user can edit some of the flds in the report, and the fields need to updated in the table. How do I proceed to accomplish this.
    Is it possible to use FM 'REUSE_ALV_DRID_DISPLAY' to do this or we need to use OOPS ALV to do this. 
    I searched for this in this forum, but couldnt get.
    Thanks in advance,
    Ananth

    You can use the REUSE_ALV_GRID_DISPLAY. and can make it a changable. You can specify the column to be changable. Once the user enters data into that coloumn the interna table automatically gets populated with the values.
    I have done a similar program. However you might need to copy some standard GUI status based on your requirements.
    Whats ur mail ID. I can send you the program I have developed.
    Shreekant

  • ALV Report Print problem after 255 character line size

    Hi ABAP Gurus,
    I have created one alv report where i am getting output more then 255 character line size.
    so whenever i tried to print this report it print only line upto first 255 character and truncated after it in printing.
    is there any way i can print this report without truncation ....
    Thanks,
    Jack

    no there is no such way because you acan print at most 99 columns and utmost 255 characters .
    and alternative is take your filed in separate screen and make it appear through hotspot in another filedcatalog.then u will get more space .
    reward if useful
    keep rockin
    vivek

Maybe you are looking for

  • Why can't I just contact Apple?

    I looked everywhere on the website for an e-mail address, but couldn't find one. I have to send my iPod in for service because it has consumed itself in destruction, and because I bought it in Canada, Canada is the only place they will return it, eve

  • NWBC - hiding/greying out buttons and OBN errors

    Hi, I'm working with Environment, Health & Safety via NWBC, but having great trouble influencing the NWBC screens. I am backend security proficient enough, however I cannot seems to figure out how the buttons on the NWBC side are controlled, hidden o

  • Cluster and transparent table

    Hi Can some one explain me what is meant by cluster and transparent table Points will be rewarded. Regards Raghu Ram.

  • How do you un disabled an ipod?

    my ipod is locked and will not unlock and i dont know how to unlock it?!

  • HT3275 My Time Machine deletes ALL previous backups

    Every so often, Time Machine deletes ALL previous backups and starts over from scratch. It has done this several times in the last year.  I have not changed any hardware or the name of the computer. Why is this happening?  Makes me very concerned tha