Column Heading are not displayed in ALV Report using CL_SALV_DISPLAY?

Hi,
   I am using CL_SALV_DISPLAY class to display data. I Created an Internal Table Dynamically based fieldcatalog which was prepared based data at run time. When i displayed data using CL_SALC_DISPALY data is display in output but column headings are not displayed.
can anyone suggest me how to display heading in ALV using CL_SALV_DISPLAY class, My code is
      CLASS lcl_report DEFINITION
CLASS lcl_report DEFINITION.
  PUBLIC SECTION.
    METHODS:
      display  IMPORTING l_table  TYPE string
                         l_fcat   TYPE string.
ENDCLASS.                    "lcl_report DEFINITION
      CLASS lcl_report IMPLEMENTATION
CLASS lcl_report IMPLEMENTATION.
  METHOD display.
    DATA: gr_table   TYPE REF TO cl_salv_table.
    DATA: gr_columns TYPE REF TO cl_salv_columns_table,
          gr_column  TYPE REF TO cl_salv_column_table,
          ls_fcat    TYPE slis_fieldcat_alv.
    DATA: gr_display TYPE REF TO cl_salv_display_settings.
    DATA: l_o_functions TYPE REF TO cl_salv_functions_list,
          l_field    TYPE string.
    FIELD-SYMBOLS : <fs_table>    TYPE STANDARD TABLE,
                    <ft_fcat>     TYPE STANDARD TABLE.
Get the ALV object refering to the output table
    ASSIGN (l_table) TO <fs_table>.
    ASSIGN (l_fcat)  TO <ft_fcat>.
    TRY.
        cl_salv_table=>factory(
          IMPORTING
            r_salv_table = gr_table
          CHANGING
            t_table      = <fs_table> ).
      CATCH cx_salv_msg.                                "#EC NO_HANDLER
    ENDTRY.
Add basic default functionality in the ALV report
Functions
    l_o_functions = gr_table->get_functions( ).
    l_o_functions->set_all( abap_true ).
    gr_columns = gr_table->get_columns( ).
    gr_columns->set_headers_visible( abap_true ).
Display the list
    gr_table->display( ).
  ENDMETHOD.                    "extract
ENDCLASS.                    "lcl_report IMPLEMENTATION
*& start-of-selection declaration
START-OF-SELECTION.
  PERFORM :
  get store codes
    get_storecodes    USING      p_stfile
                      CHANGING   it_t001w,
  fetching mard data
    read_mard_data,
  preparing fieldcatalog for Final Data
    create_filedcat   USING      it_t001w
                                 it_site
                      CHANGING   it_fieldcat,
  preparing structure & internal table for Final Data
    create_final_table_structure  USING  it_fieldcat,
  prepare output data
    prepare_final_data.
*& end-of-selection declaration
END-OF-SELECTION.
  PERFORM :
  display data
    display_data    USING l_table
                          l_fcat.
*&      Form  get_storecodes
FORM get_storecodes  USING    p_p_stfile
                     CHANGING p_it_t001w  LIKE it_t001w[].
  DATA  :
internal table for RAW
  lt_raw    TYPE truxs_t_text_data,
  rs_site   LIKE LINE OF rt_site,
  l_index   LIKE sy-tabix.
  FIELD-SYMBOLS :
field symbol for it_t001w
  <fs_t001w>   LIKE LINE OF p_it_t001w.
calling function module to get Stores Data from File
  CALL FUNCTION 'TEXT_CONVERT_XLS_TO_SAP'
    EXPORTING
      i_line_header        = 'X'
      i_tab_raw_data       = lt_raw
      i_filename           = p_p_stfile
    TABLES
      i_tab_converted_data = p_it_t001w[]
    EXCEPTIONS
      conversion_failed    = 1
      OTHERS               = 2.
  IF sy-subrc <> 0.
    EXIT.
  ENDIF.
  SORT p_it_t001w BY werks.
  CLEAR rs_site.
  rs_site-sign   = 'I'.
  rs_site-option = 'EQ'.
  rs_site-low    = p_dccode.
  APPEND rs_site TO rt_site.
  IF it_t001w[] IS NOT INITIAL.
    LOOP AT p_it_t001w ASSIGNING <fs_t001w>.
      l_index   = sy-tabix.
      CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
        EXPORTING
          input  = <fs_t001w>-werks
        IMPORTING
          output = <fs_t001w>-werks.
      MODIFY p_it_t001w FROM <fs_t001w> INDEX l_index.
      IF <fs_t001w>-werks GE s_site-low AND <fs_t001w>-werks LE s_site-high.
      append site to ranges
        CLEAR rs_site.
        rs_site-sign   = 'I'.
        rs_site-option = 'EQ'.
        rs_site-low    = <fs_t001w>-werks.
        APPEND rs_site TO rt_site.
        CONTINUE.
      ENDIF.
    ENDLOOP.
    SORT p_it_t001w BY werks.
    SORT rt_site.
  ENDIF.
ENDFORM.                    " get_storecodes
*&      Form  create_final_table_structure
FORM create_filedcat   USING    p_it_t001w      LIKE it_t001w[]
                                p_it_site       LIKE it_site[]
                       CHANGING p_it_fieldcat   LIKE it_fieldcat[].
  FIELD-SYMBOLS :
field symbol for p_it_t001w
  <fs_t001w>     LIKE LINE OF p_it_t001w,
field symbol for p_it_site
  <fs_site>      LIKE LINE OF p_it_site.
  DATA :
fieldname
  l_fieldname    TYPE slis_fieldname,
workarea for site ranges
  rs_site        LIKE LINE OF rt_site.
  CLEAR : l_fieldname, rs_site.
  l_fieldname    = p_dccode.
  PERFORM
prepare fieldcatalog
  build_fieldcatalog USING :   'MTART'      'CHAR'        '5'  ,
                               'MTBEZ'      'CHAR'        '25' ,
                               'MATKL'      'CHAR'        '6'  ,
                               'WGBEZ'      'CHAR'        '20' ,
                               'MATNR'      'CHAR'        '18' ,
                               'MAKTX'      'CHAR'        '30' ,
                                l_fieldname 'CHAR'        '17' .
create header for excel
  PERFORM create_excel_header USING  : 'Division',
                                       'Divsion Description',
                                       'MC Code',
                                       'MC Description',
                                       'Article',
                                       'Article Description',
                                        l_fieldname.
loop for creating fieldcatalog
  LOOP AT it_site ASSIGNING <fs_site>.
    READ TABLE it_t001w ASSIGNING <fs_t001w> WITH KEY werks = <fs_site>-werks
                                                              BINARY SEARCH.
    IF sy-subrc = 0           AND <fs_t001w> IS ASSIGNED AND
       <fs_site> IS ASSIGNED  AND <fs_site>-stock GT 0.
      CLEAR : l_fieldname, rs_site.
      l_fieldname    = <fs_site>-werks.
    prepare fieldcatalog
      PERFORM build_fieldcatalog USING : l_fieldname    'CHAR'   '17'.
    create header for excel
      PERFORM create_excel_header USING  l_fieldname  .
      CONTINUE.
    ENDIF.
  ENDLOOP.
  l_fcat  = 'it_fieldcat[]'.
ENDFORM.                    " create_final_table_structure
*&      Form  build_fieldcatalog
FORM build_fieldcatalog  USING    p_fieldname      TYPE slis_fieldname
                                  p_datatype       TYPE datatype_d
                                  p_length         TYPE intlen.
  DATA : ls_fieldcat    LIKE LINE OF it_fieldcat.
  CLEAR  : ls_fieldcat.
  ls_fieldcat-fieldname   = p_fieldname.
  ls_fieldcat-datatype    = p_datatype.
  ls_fieldcat-intlen      = p_length.
  APPEND ls_fieldcat TO it_fieldcat.
ENDFORM.                    " build_fieldcatalog
*&      Form  create_final_table_structure
FORM create_final_table_structure  USING    p_it_fieldcat.
Create dynamic internal table and assign to FS
  CALL METHOD cl_alv_table_create=>create_dynamic_table
    EXPORTING
      it_fieldcatalog = it_fieldcat
    IMPORTING
      ep_table        = t_table.
  ASSIGN t_table->*  TO <ft_final>.
ENDFORM.                    " create_final_table_structure
*&      Form  create_excel_header
FORM create_excel_header  USING    p_p_fieldname.
  DATA : ls_header  LIKE LINE OF it_header.
  CLEAR ls_header.
  ls_header-col_name  = p_p_fieldname.
  APPEND ls_header TO it_header.
ENDFORM.                    " create_excel_header
*&      Form  prepare_final_data
FORM prepare_final_data .
  DATA          : l_matnr       LIKE g_matnr,
                  l_werks       LIKE g_werks,
                  l_index       LIKE sy-tabix.
  FIELD-SYMBOLS : <fs_mard>     LIKE LINE OF it_mard.
Getting No. of Lines in IT_MARD internal table
  DESCRIBE TABLE it_mard LINES g_lines.
  LOOP AT it_mard ASSIGNING <fs_mard>.
    l_index    = sy-tabix.
    IF l_matnr IS INITIAL.
      l_matnr  = <fs_mard>-matnr.
      CLEAR : l_werks.
      l_werks    = <fs_mard>-werks.
      UNASSIGN : <fs_value>, <fs_final>.
    Create dynamic work area and assign to FS
      CREATE DATA t_line LIKE LINE OF <ft_final>.
      ASSIGN t_line->*   TO <fs_final>.
      ASSIGN COMPONENT 'MATNR'  OF STRUCTURE <fs_final> TO <fs_value>.
      <fs_value>        = <fs_mard>-matnr.
      ASSIGN COMPONENT l_werks  OF STRUCTURE <fs_final> TO <fs_value>.
      <fs_value>        = <fs_value> + <fs_mard>-labst.
    getting Article Type,MC & its Descriptions
      PERFORM get_other_data    USING     l_matnr
                                          l_werks.
    ELSEIF l_matnr <> <fs_mard>-matnr.
      APPEND <fs_final> TO <ft_final>.
      CLEAR l_matnr.
      l_matnr  = <fs_mard>-matnr.
      CLEAR : l_werks.
      l_werks    = <fs_mard>-werks.
      UNASSIGN : <fs_value>, <fs_final>.
    Create dynamic work area and assign to FS
      CREATE DATA t_line LIKE LINE OF <ft_final>.
      ASSIGN t_line->*   TO <fs_final>.
      ASSIGN COMPONENT 'MATNR'  OF STRUCTURE <fs_final> TO <fs_value>.
      <fs_value>        = <fs_mard>-matnr.
      ASSIGN COMPONENT l_werks  OF STRUCTURE <fs_final> TO <fs_value>.
      <fs_value>        = <fs_value> + <fs_mard>-labst.
    getting Article Type,MC & its Descriptions
      PERFORM get_other_data    USING     l_matnr
                                         l_werks.
    ELSE.
      CLEAR : l_werks.
      l_werks    = <fs_mard>-werks.
      ASSIGN COMPONENT l_werks  OF STRUCTURE <fs_final> TO <fs_value>.
      <fs_value>        = <fs_value> + <fs_mard>-labst.
    ENDIF.
    IF l_index = g_lines.
      APPEND <fs_final> TO <ft_final>.
    ENDIF.
  ENDLOOP.
  l_table  = '<ft_final>[]'.
ENDFORM.                    " prepare_final_data
*&      Form  get_other_data
FORM get_other_data  USING    p_l_matnr
                              p_l_werks.
  FIELD-SYMBOLS : <fs_mara>     LIKE LINE OF it_mara,
                  <fs_t023t>    LIKE LINE OF it_t023t,
                  <fs_t134t>    LIKE LINE OF it_t134t,
                  <fs_makt>     LIKE LINE OF it_makt.
  READ TABLE it_mara ASSIGNING <fs_mara> WITH KEY matnr = p_l_matnr.   " BINARY SEARCH.
  IF sy-subrc = 0 AND <fs_mara> IS ASSIGNED.
    ASSIGN COMPONENT 'MTART'  OF STRUCTURE <fs_final> TO <fs_value>.
    <fs_value>        = <fs_mara>-mtart.
    ASSIGN COMPONENT 'MATKL'  OF STRUCTURE <fs_final> TO <fs_value>.
    <fs_value>        = <fs_mara>-matkl.
    READ TABLE it_makt  ASSIGNING <fs_makt>  WITH KEY matnr =  <fs_mara>-matnr   BINARY SEARCH.
    IF sy-subrc = 0 AND <fs_makt> IS ASSIGNED.
      ASSIGN COMPONENT 'MAKTX'  OF STRUCTURE <fs_final> TO <fs_value>.
      <fs_value>        = <fs_makt>-maktx.
    ENDIF.
    READ TABLE it_t023t ASSIGNING <fs_t023t> WITH KEY matkl = <fs_mara>-matkl  BINARY SEARCH.
    IF sy-subrc = 0 AND <fs_t023t> IS ASSIGNED.
      ASSIGN COMPONENT 'WGBEZ'  OF STRUCTURE <fs_final> TO <fs_value>.
      <fs_value>      = <fs_t023t>-wgbez.
    ENDIF.
    READ TABLE it_t134t ASSIGNING <fs_t134t> WITH KEY mtart = <fs_mara>-mtart  BINARY SEARCH.
    IF sy-subrc = 0 AND <fs_t134t> IS ASSIGNED.
      ASSIGN COMPONENT 'MTBEZ'  OF STRUCTURE <fs_final> TO <fs_value>.
      <fs_value>      = <fs_t134t>-mtbez.
    ENDIF.
  ENDIF.
ENDFORM.                    " get_other_data
*&      Form  display_data
      text
FORM display_data  USING    p_l_table
                            p_l_fcat.
  DATA:
Variable for Object Creation
  o_report TYPE REF TO lcl_report.
  CREATE OBJECT o_report.
  o_report->display( EXPORTING l_table = p_l_table
                               l_fcat  = p_l_fcat ).
ENDFORM.                    " display_data

I don't know how to read the code you pasted or I would have checked this myself.
Do your fields in the internal table reference dictionary objects or elementary types? If not using dictionary types, the column names will be blank by default. If you can't change your fields to be dictionary types, you can try this to change the column names:
I made a method inside my local class to add the names:
        call method set_colname
          EXPORTING iv_tab = alv_tab
                    iv_colid = 'xxxx'  "fieldname from the table
                    iv_stxt = text-t54
                    iv_mtxt = text-t55
                    iv_ltxt = text-t55.
METHOD set_colname .
  data:
          alv_cols type REF TO cl_salv_columns_table,
          alv_col type REF TO cl_salv_column.
  TRY .
*... Change fieldnames
        call METHOD iv_tab->get_columns RECEIVING value = alv_cols.
        call method alv_cols->get_column EXPORTING columnname = iv_colid RECEIVING value = alv_col.
        IF iv_stxt <> ''.
          CALL METHOD alv_col->set_short_text EXPORTING value = iv_stxt.
        ENDIF.
        IF iv_mtxt <> ''.
          CALL METHOD alv_col->set_medium_text EXPORTING value = iv_mtxt.
        ENDIF.
        IF iv_ltxt <> ''.
          CALL METHOD alv_col->set_long_text EXPORTING value = iv_ltxt.
        ENDIF.
   CATCH cx_salv_not_found.
  ENDTRY.
ENDMETHOD. "set_colname

Similar Messages

  • Enabled UDF's are not displaying in XL Report Composer.

    Hi,
    I Enabled User Defined Fields (UDF) under manage user defined fields. But itu2019s displaying only Light dimensionu2018s fields. But Dimension attributeu2019s fields are not displaying in XL Report composer. How we can display Dimension attribute fields in XL Report.
    Regds,
    Sampath Kumar.

    Hi,Danie Posthumus
    First of all we are not able to see my User define filed in report composer except for light dimensions type. Only we are getting Light Dimension Data Item type only we are not getting Dimension Attribute Data item type.
    Regds,
    Sampath Kumar Devunuri.

  • IR column Header value not displayed entirely during filteration

    I have a IR, when I click any column Header and it shows the list of values as a dropdown.
    some of them (which are larger) get cut off.. means the the entire content/value are not displayed within the dropdown. [width of dropdown is fixed and no of characters in the content/value is more..]
    how can we fix this?
    Also.. is there any we can increase the width of the Select List window when we click any column header in IR.
    Thanks,
    Deepak
    Edited by: DeepakJ on Sep 15, 2011 4:08 PM

    Hi,
    jQuery is not included to Apex 3.2 by default.
    If you have not include jQuery library's to e.g. your page template or page header, then it is not "installed".
    You can run your app and inspect HTML source to be sure.
    You can download jQuery and jQuery UI and place files to your HTTP server folder. Then load those in e.g. page template header.
    Or use jQuery files from Google by placing to page template header.
    <link type="text/css" rel="stylesheet" href="//ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/themes/redmond/jquery-ui.css" />
    <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js"></script>
    <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.min.js"></script>Regards,
    Jari

  • 0.00 is currency not displaying in ALV REPORT......

    Hi All,
    There is a currency field in the internal table which is not displaying only value 0.00 if the value is 0.03 then it is displaying in ALV.
    I have checked the Internal Table passed in the FM: REUSE_ALV_LIST_DISPLAY but it is carrying the value 0.00. But while displaying it is not displaying in the report.
    I have also checked the Field catalogue there is no such conditions mentioned.
    Kindly help me.
    Thanks in Advance.
    MP

    Hi MP,
    while handling witht eh currency fields make sure that the following are taken care of
    in the field catalog use:
    gs_field-datatype = 'CURR'.
    gs_field-inttype = 'C'.
    also the following
    fieldcatalog-no_zero = 'X'. should be taken care of otherwise it will not display the zeros appearing in the final internal table for ALV display.
    Hope its helpful
    Thanks,
    Srikanth.P

  • APD - Column Headers are not displaying properly when downloaded

    Hi All,
    I am trying to download a simple query as a comma delimited file on my desktop using APD.
    When I execute the APD, the all the data getting properly downloaded as required but I am facing the following problems.
    1) The column heading are coming as  garbage characters particularly for keyfigures
    2) The keyfigures are getting displayed first and then characters, I expect them similarly the query display
    3) I don't want to display the UNITS of the keyfigures to be displayed.
    Please let me know if anybody has idea on this.
    Regards,.
    Tapan

    Hi Tapan,
    Try using "Hide or Rename Columns(projection)".
    This allows you to rearrange the order of columns in file and also to rename the descriptions as needed.
    Regards,
    Vidya Sagar

  • External images are not displaying in RDLC report

    I need to add an external image in my RDLC report. My issue is the image has to come from an external site URL. I passed the URL using report parameter, but doesn't show any output. However, if I pass the URL directly in the RDLC report in the image control
    it displays the image. Since this doesn't make the report dynamic, I need to know how to make Image display in RDLC report using report parameter.

    Try below:
    http://www.codeproject.com/Questions/440205/Display-image-on-rdlc-report-viewer
    Dim paramList1 AsNew Generic.List(Of ReportParameter)
    paramList1.Add(New ReportParameter("Path", "+ /images/CPC.jpg")) Me.ReportViewer1.LocalReport.SetParameters(paramList1)
    http://www.c-sharpcorner.com/uploadfile/abylex/show-images-in-reports-at-run-time-using-reportviewer/
    If you do not have images in your Application. That is, you want to use an external image.
    a. Use an Image control on your RDLC file.
    b. Set the Image's Property-Source = External.
    c. Reserve a Report's DataSource Member for the image Path. For example-
    DataSource.ImgPath.
    d. Set the value for image path from the code in DataSource.ImgPath.
        For example:
    DataSource.ImgPath = "http://www.google.com/intl/en_ALL/images/logo.gif";
    e. The following self explanatory code also needs to be written:
        reportViewer1.LocalReport.EnableExternalImages = true; 
    (reportViewer1
    is the Name for the   ReportViewer Control)
    f. Do the normal stuff to bind DataSource etc.
    g. Done. Enjoy your image in the Report.
    If this helped you resolve your issue, please mark it Answered

  • Heirarchy values are not displaying correctly in report.

    Hi,
    I am having a heirarchy field in my report.
    I have 2 local RKF's in my report and 2 manadatory variables(which are FISCAL YEAR AND CAL MONTH).
    When i am executing the report , it is displaying the Heirarchy values with respect to one restricted KF.
    The heirarchy values correspoding to other RKF are not getting displayed properly, it is showing as (NOT Assigned).
    Its giving the correct values for the RKF's but not showing the  heirarchy values.
    I hided the 2nd RKF, then also its showing in the same way.
    Please help me on this,
    Thanks in advance!

    Hi, Saro,
    >
    I have taken a std. report to customize, and the name of the report is Asset Retirements from Fixed Asset module.
    From the existing base query, i have added some query to customize it.
    I have summed  the cost column in the report using summary column.
    For example, im passing a parameters which displays 5 lines in the report output. Im getting the cost value correctly in all the 5 lines, but when i tried to sum all the 5 lines, it is taking the first line of cost value and it is not summing the cost value of all the 5 lines in the report. I dont know why this problem occurs.
    Summary column should be place one level up of the query and set the following values under summary
    Function
    Source
    Reset As

  • SET command and column heading are not working

    Hi All,
    Am trying to create sql reports using SET and Column headings as given below.It's saying missing or invalid option.
    But when i execute this in SQL*PLUS it's working fine.. is this limitation in AE edition. Please advice.
    Also tried with sql script execution, still same problem.
    set pagesize 100;
    set linesize 80;
    column ename heading "employee name";
    select * from emp;
    Regards,
    Anil

    user575819 wrote:
    Please update your forum profile with a real handle instead of "user575819".
    Am trying to create sql reports using SET and Column headings as given below.It's saying missing or invalid option.
    But when i execute this in SQL*PLUS it's working fine.. is this limitation in AE edition. Please advice.
    Also tried with sql script execution, still same problem.
    set pagesize 100;
    set linesize 80;
    column ename heading "employee name";
    select * from emp;
    SET and COLUMN are SQL*Plus client commands, not part of the SQL language, and thus they cannot be used in APEX report queries. Consult the APEX documentation for information on creating reports. If you are unfamiliar with APEX, start with the 2 Day Developer's Guide tutorial, which covers creating APEX reports.

  • No column heading in second page in alv report when save in excel file

    Hi Expert,
    How can i remove the column header from Alv report when program execute in background and save in excel file right now
    its comming column header in each page. Client dont want header column in excel from second page. is this possible?
    with regards
    chandan_viji

    Hi Ravi,
    thanks for reply i have solved this problm throug line count and NEW-PAGE LINE COUNT 10000 bcoz client want output in excel file only one page header.
    with regards
    chandan_viji

  • Sub total icon is not displaying in alv report output

    Hi friends ,
    In alv report display on menu bar the icon : subtotals is not displaying at the output , I should not give subtotal in each field catalog .
    Plz give me solution, points will be rewarded.
    with regards,
    prasad.

    Hi,
    I think u r using PF-STATUS parameter in function module,
    if u use this parameter, you sholud give the icon name etc..
    otherwise by default it will appear.
    Check your code again.
    Give me exact requirement, if possible paste the code.
    Regards,
    Chandu

  • Header is not displaying Properly in Report.

    CONCATENATE 'Company Name :' text1 INTO text1.
      CREATE OBJECT lr_grid.
      lr_grid->create_text(
          row = 1
          column = 1
          text = text1
       CONCATENATE 'Plant :' text1 INTO text1.
      CREATE OBJECT lr_grid.
      lr_grid->create_text(
          row = 2
          column = 1
          text = text1
      CONCATENATE 'Unit Name :' unit_text INTO unit_text.
      CREATE OBJECT lr_grid.
      lr_grid->create_text(
          row = 3
          column = 1
          text = unit_text
       CONCATENATE 'REPORT NAME:' text1 INTO text1.
      CREATE OBJECT lr_grid.
      lr_grid->create_text(
          row = 4
          column = 1
          text = text1
    I have created 4 heading for report using above method but its displaying only two in output.Kindly let me know how can i display it properly.
    Thanks.
    Added code tags
    Edited by: Suhas Saha on Aug 19, 2011 11:01 AM

    DATA  : lr_grid  TYPE REF TO cl_salv_form_layout_grid,
              text1(50) TYPE c,
              unit_text(50) TYPE c,
              plant_text(50) TYPE c,
              lr_text TYPE REF TO cl_salv_form_text.
    cl_salv_form_layout_grid is type of class.Im new to oops so plz guide me.....
    Edited by: abhi1582 on Aug 19, 2011 7:05 AM

  • New field category not display in ALV report

    Hi,
    Hi, I modifying an existing ALV report.
    I have a problem to insert the new field into the ALV report.
    The field and column title have been populated in alv field category correctly, but when FM 'REUSE_ALV_GRID_DISPLAY'  executed, the new field and column didn't appear.
    Anybody can help me.
    Regards
    Nislina

    hi
    Add that new field in the fieldcatalog and populate the value in the value in the internal table.
    loop at it_fieldcatalog into wa_fieldcatalog.
    wa_fieldcatalog-fieldname = 'NEW_FIELD'.
    wa_fieldcatalog-outputlen = '15'.
    append wa_fieldcatalog to it_fieldcatalog.
    clear wa_fieldcatalog,
    endloop.
    regards
    ravish
    <b>plz reward points if helpful</b>

  • In XML Output the values of Number column tags are not displayed properly

    Hi,
    Our Client have been using AR Invoice Print Program for a long time and it is heavily customized. Also they are using an old version of the RDF. So we have taken the latest version of the RDF (RAXINV.rdf) for Oracle Apps 11.5.10.2 by raising a SR and implement Client's old RAXINV.rdf into it.
    All was ok, but when we are running the program, the XML Output did not generate properly. For the Q_INVOICE query (G_ORDER_BY, G_INVOICE and G_INV_TERM group), the value of some of the scaler number columns are not appeared properly. The tags are coming correctly, but the value is appearing as '*', instead of the correct value. We have checked in the RDF Level (By putting srw.message and check in the log file) that those columns are having proper value. So there is no issue with the RDF.
    But because of the above mentioned problem, the some of the PDF output field values also is not generated correctly.
    I think that because of the lexical parameters which was implementing the Q_INVOICE query (&COMMON_QUERY) this issue is coming. Because the issue is only in the Q_INVOICE query group (G_ORDER_BY, G_INVOICE and in G_INV_TERM group) not in any other query group.
    There is no problem with the scaler character columns. The issue is only with the number columns.
    Also we have checked that if we hardcode the value of the number columns in the above mentioned lexical parameter, this problem doesn't appear.
    If we put TO_CHAR function to those number columns in the lexical parameter (COMMON_QUERY), then this issue get solved. But we can't do it because of performance issue and also Client won't approve it.
    Please help.
    With Thanks and Regards

    I don't know how to read the code you pasted or I would have checked this myself.
    Do your fields in the internal table reference dictionary objects or elementary types? If not using dictionary types, the column names will be blank by default. If you can't change your fields to be dictionary types, you can try this to change the column names:
    I made a method inside my local class to add the names:
            call method set_colname
              EXPORTING iv_tab = alv_tab
                        iv_colid = 'xxxx'  "fieldname from the table
                        iv_stxt = text-t54
                        iv_mtxt = text-t55
                        iv_ltxt = text-t55.
    METHOD set_colname .
      data:
              alv_cols type REF TO cl_salv_columns_table,
              alv_col type REF TO cl_salv_column.
      TRY .
    *... Change fieldnames
            call METHOD iv_tab->get_columns RECEIVING value = alv_cols.
            call method alv_cols->get_column EXPORTING columnname = iv_colid RECEIVING value = alv_col.
            IF iv_stxt <> ''.
              CALL METHOD alv_col->set_short_text EXPORTING value = iv_stxt.
            ENDIF.
            IF iv_mtxt <> ''.
              CALL METHOD alv_col->set_medium_text EXPORTING value = iv_mtxt.
            ENDIF.
            IF iv_ltxt <> ''.
              CALL METHOD alv_col->set_long_text EXPORTING value = iv_ltxt.
            ENDIF.
       CATCH cx_salv_not_found.
      ENDTRY.
    ENDMETHOD. "set_colname

  • JTable column header is not displaying

    Here I have the sample code which is not displaying the header names of each row (Names, Size, Status).
    import javax.swing.*;
    import javax.swing.table.*;
    import java.awt.*;
    public class sample extends JFrame
        JTable table;
        String names[] = {"Names","Size","Status"};
        TableModel model = new AbstractTableModel()
            public Object getValueAt(int row, int col)
                return "Data";
            public int getColumnCount()
                return 3;
            public int getRowCount()
                return 5;
            public String getColumnName(int col)
                return names[col];
        public sample()
            setSize(400,400);
            setDefaultCloseOperation(3);
            Container cp = getContentPane();
            table = new JTable(model);
            cp.add(table);
            setVisible(true);
        public static void main(String a[])
            new sample();
    }Anybody can give idea for me.

    Read the JTable API. It shows you how to do this. In addition it has a link to the tutorial on "How to Use Tables" which contains many examples.

  • Images in some Column-Heads are not visible

    Hi there,
    in an Webdynpro-Application I am using tables that are sorted in that way that is discribed in the Tables-Tutorial (with TableSort-Class). Everything works fine except that initially there is no image in the column-head although I set one in the layout-designer. After sorting the apropriate images appear.
    I tried to set the image-source again, I tried to set the image in the source like:
    <i>IWDTable table = (IWDTable)view. ...
    table.getColumns()[...].getHeader().setImageSource("...");</i>
    ... doesn't work.
    Are there solutions? Thanks!<i></i>

    Hi,
    Your code is right. but i think you have placed the setImageSource code before the call of Table Sorter class.
    if you put that code after the object creation of TableSorter class, it will work.
    regards
    Karthik

Maybe you are looking for

  • Last page rasterizing when exporting to EPUB from Indesign

    Hello all, I  currently have a problem with the last page of my EPUB book rasterizing. This shows up in both Adobe digital Additions and iBooks. I cannot fathom why it is doing it, is there anyone who has come across this before? fyi. It doesnt seem

  • Where is hide/show toolbar button?

    Hello all, I have purchased Aperture as a retail package, and I am running Snow Leopard.  I have a "hide/show Toolbar" button in the upper left of the title bar, as indicated in the included screenshot. I used Aperture on a friend's machine, and he d

  • Shopping cart disconnect is ruining my business!!

    Situation #1:Buyer put 3 items in his cart and tried to request combined shipping and eBay would not allow it. I told him to use the shopping cart on eBay.ca instead or to "commit to buy". He then responded that he was on eBay.ca and that it wouldn't

  • IWeb still won't publish. At All. Tired and fed up

    Hi, yesterday I posted a Help note saying that iWeb was refusing to publish my website. I got some advice back from James Tseng (thanks James) saying I should keep trying. Well, I have kept trying - this is a day later - and i still get the message:

  • Getting CS6 to work

    I have downloaded CS6. To run the file it says files must be extracted. I did that and nothing happens. What now?