Data of alv report in  excel file in background processing using open datas

Hi Experts,
I have developed report for purchase register . if i execute this report in background process i am not able to get the downloaded file in excel and output is also not coming properly, columns are going to overlap.
i used open dataset  read dataset and close dataset but still problem is not solved. so if anyone have code with this and also which will have concatenate statement in the code send it.
Regards,
Rahul

Hi Rahul,
Ur code shud be like below:
DATA : l_filename2 TYPE string,
            v_extn.
    SPLIT p_filename AT '.xls' INTO l_filename2  v_extn.
    CONCATENATE l_filename2  'downloaded'  INTO l_filename2  SEPARATED BY '_'.
    CONCATENATE l_filename2  'txt'   INTO l_filename2 SEPARATED BY '.'.
    OPEN DATASET l_filename2 IN TEXT MODE FOR OUTPUT ENCODING DEFAULT.
    IF sy-subrc <> 0.
      MESSAGE e499(sy) WITH text-e02.
    ENDIF.
    LOOP AT it_order_number INTO wa_order_number.
      TRANSFER wa_order_number TO l_filename2.
    ENDLOOP.
    CLOSE DATASET l_filename2.
Now, go to tcode AL11 and check it in the Application server itself.
Hope this helps,
Regards,
Arnab.

Similar Messages

  • Upload data from multiple worksheets of excel file into SAP by using MIME?

    Hi all,
    I'm trying to getting the data from a multiple worksheet excel file by usin the MIME Repository.
    First of all i realizied it like [here|http://abap-explorer.blogspot.com/2008/12/upload-data-from-multiple-worksheets-of.html] in a normal ABAP Report.
    By trying to transfer the code to a WebDynpro Component, i get problems.
    With this part of code, because ActiveX is not allowed in our Webbrowser. So i have to find another solution to get the data from the excel file.
    CALL METHOD c_oi_container_control_creator=>get_container_control
    IMPORTING
    control = iref_control
    error   = iref_error
    I tried to rebuild this solution in webdynpro. But it dont works.
    So my next step was trying to Read the Excel sheet directly from MIME by getting the Content (XString).
    But there is no useful information Just a mix out of '######' and other symbols.
    By converting it into String the same problem.
    Maybe someone has an idea how to rebuild [this code|http://abap-explorer.blogspot.com/2008/12/upload-data-from-multiple-worksheets-of.html] in Webdynpro that it works correctly.
    Currently Im Using the Fileupload UI Element. All Works fine. I can Upload the Excel file to MIME Repository and i can open it from there.
    But i cant get the same clear informationen from the file, to write it later in a Database, like before without webdynpro.
    i hope someone can help me.
    Edited by: Sascha Baumann on Apr 20, 2009 4:28 PM

    You can't read the native binary Excel Format in server side ABAP.  The functions and classes that did this in Classic Dynpro used OLE Automation via the SAPGUI Control Framework to remotely control Excel to read the data.  Because in the browser you have no connection to the SAPGUI or are sandboxed inside the browser; the same functionality is not possible. 
    I would suggest that you look into saving the Excel file as a open, text format.  You might be able to use XML (although the Excel XML format can be complex) to support multiple sheets. You would have to build the logic yourself (using XSLT or the iXML parser) to process the XML format back into ABAP data.

  • How to Create Excel File in Background processing with different colors

    HI All
    I am trying to create Excel file in background & send it to user through e-mail, this i could acheive using fucntion module SO_DOCUMENT_SEND_API1, but here my requirement is i want to put different colors to columns of excel & this should happen in Background processing,
    Initially i completed above requirement by using HTML type of document with attachment type 'ALI'  & formatted output using write statement & used colors, after that i took this o/p using save_list function module & then table compress...etc.
    but i don't know how to achieve same if we need o/p in excel as size of object of excel file is less than that of HTML
    I am thankfull to everybody who will help me.
    Regards
    Lokesh

    Lokesh,
    Iam also trying to populate my text file with colors as an attachment . If you know this please let me know.

  • Save alv report as excel file directly from program

    Hello guys,
    I require this in my work.
    I want to save the ALV report tat is to be generated in the filepath that is given in the selection screen (want to save it locally eg: my windows desktop) and in the layout which is also given in the selection screen.
    your comments will be very much appreciated.
    Thanks in Advance,
    Johny

    Hi Johny,
    Actually we have an option to download report output in ALV but it does not download the specified on Selection-screen. For this Create on button for Excell download by setting PF status. and use USER_COMMAND event to trigger when u click on the button and download data to specified path.
    1.
    declare events table like this.
    data :
          i_events  type slis_t_event,
          w_events  like line of i_events.
    2.
    Build events table .
    w_events-name = 'USER_COMMAND' .
    w_events-form = 'USER_COMMAND' .
    append w_events to i_events.
    clear w_events.
    w_events-name = 'PF_STATUS_SET' .
    w_events-form = 'PF_STATUS_SET' .
    append w_events to i_events.
    clear w_events.
    3.
    pass this events table through REUSE_ALV_GRID_DISPLAY.
    4.
    USER_COMMAND and PF_STATUS_SET call back subroutines should be like this in your case. These are nowhere called using PERFORM statement in ur program.
    5.
    PF_STATUS_SET' subroutine should be like this.
    *&      Form  pf_status_set
    form pf_status_set    using extab type slis_t_extab.
    set pf-status 'STATUS1' excluding g_extab.
    "If you write like above Standard status will be gone.
    "For that u have to copy standard status of any ALV program which has standard status.
    "1. goto SE41 tcode. give program SAPLKKBL and status :STANDARD_FULLSCREEN .
    2.Click on the Copy status button below program is ur program and status ur program status.
    3. After that create your own button for Excel downlod.
    endform.                    "pf_status_set
    6.
    USER_COMMAND subroutine should be like this.
    *&      Form  user_command
    form user_command using ucomm like sy-ucomm
                      selfield type slis_selfield.
      case ucomm .
        when 'XLS_DOWN'.
        perform download_to_xls.
      endcase.
    endform.                    "user_command
    Here is the sample program to download data into Excel file with header and Columns..
    Check this program by running.
    *& Report  ZVENKAT_DOWNLOAD_XLS_WITH_HEAD
    REPORT  zvenkat_download_xls_with_head.
    "  Data retrieval related declarations
    TYPES:
         BEGIN OF t_emp_dat,
           pernr TYPE pa0001-pernr,
           persg TYPE pa0001-persg,
           persk TYPE pa0001-persk,
           plans TYPE pa0001-plans,
           stell TYPE pa0001-stell,
         END OF t_emp_dat,
         t_attachment TYPE  solisti1.
    DATA:
         w_emp_data TYPE t_emp_dat,
         w_attachment     TYPE  t_attachment.
    DATA:
         i_emp_data TYPE STANDARD TABLE OF t_emp_dat,
         i_attachment     TYPE STANDARD TABLE OF t_attachment.
    PARAMETERS: p_file TYPE string DEFAULT 'c:\tmp\test.xls'.
    "Start-of-selection.
    START-OF-SELECTION.
      PERFORM get_data.
      PERFORM build_xls_data_and_download.
      "Form  get_data from PA0001
    FORM get_data.
      SELECT pernr
             persg
             persk
             plans
             stell
       FROM pa0001
       INTO CORRESPONDING FIELDS OF TABLE i_emp_data
       UP TO 4 ROWS.
    ENDFORM.                    " get_data
    "Form  build_xls_data_and_download
    FORM build_xls_data_and_download.
      "If you have Unicode check active in program attributes then
      "you will need to declare constants as follows.
      CLASS cl_abap_char_utilities DEFINITION LOAD.
      CONSTANTS:
          con_tab  TYPE c VALUE cl_abap_char_utilities=>horizontal_tab,
          con_cret TYPE c VALUE cl_abap_char_utilities=>cr_lf.
      DATA :l_lines TYPE char10.
      DESCRIBE TABLE i_emp_data LINES l_lines.
      CONCATENATE 'Total no of records:' l_lines
             INTO  w_attachment
    SEPARATED BY  con_tab.
      CONCATENATE con_cret
                  w_attachment
             INTO w_attachment.
      APPEND w_attachment TO i_attachment.
      CLEAR  w_attachment.
      CONCATENATE 'PERNR' 'PERSG' 'PERSK' 'PLANS' 'STELL'
             INTO  w_attachment
    SEPARATED BY  con_tab.
      CONCATENATE con_cret
                  w_attachment
             INTO w_attachment.
      APPEND w_attachment TO i_attachment.
      CLEAR  w_attachment.
      LOOP AT i_emp_data INTO w_emp_data.
        CONCATENATE w_emp_data-pernr
                    w_emp_data-persg
                    w_emp_data-persk
                    w_emp_data-plans
                    w_emp_data-stell
               INTO w_attachment
       SEPARATED BY con_tab.
        CONCATENATE con_cret w_attachment
               INTO w_attachment.
        APPEND w_attachment TO i_attachment.
        CLEAR  w_attachment.
      ENDLOOP.
      CALL FUNCTION 'GUI_DOWNLOAD'
        EXPORTING
          filename              = p_file
          write_field_separator = con_tab
        TABLES
          data_tab              = i_attachment.
      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_xls_data_and_download
    I hope that it helps u .
    Regards,
    Venkat.O

  • How to Downlaod Data from Alv List to Excel File

    Hi,
      I have a Requirement like While download data from ALV to Excel File .After Download data into Excel we will not allow user to edit the Excel data..
    Plz  help me to complete this scenario.
    Thanks & Regards,
    Kumaran Duraiswamy.

    hi,
    try these following fm's
    MS_EXCEL_OLE_STANDARD_DAT
    EXCEL_OLE_STANDARD_DAT
    CALL FUNCTION 'MS_EXCEL_OLE_STANDARD_DAT'
    EXPORTING
    file_name = 'Your Path' " enter your path to save the file.
    CREATE_PIVOT = 0
    * DATA_SHEET_NAME = ' '
    * PIVOT_SHEET_NAME = ' '
    * PASSWORD = ' '
    * PASSWORD_OPTION = 0
    VISIBLE = '0'
    No_DIALOG = 'X'
    TABLES
    * PIVOT_FIELD_TAB =
    DATA_TAB = t_deli_final
    * FIELDNAMES =
    EXCEPTIONS
    FILE_NOT_EXIST = 1
    FILENAME_EXPECTED = 2
    COMMUNICATION_ERROR = 3
    OLE_OBJECT_METHOD_ERROR = 4
    OLE_OBJECT_PROPERTY_ERROR = 5
    INVALID_FILENAME = 6
    INVALID_PIVOT_FIELDS = 7
    DOWNLOAD_PROBLEM = 8
    OTHERS = 9
    IF sy-subrc 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    * WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    2nd fm
      CALL FUNCTION 'EXCEL_OLE_STANDARD_DAT'
           EXPORTING
                FILE_NAME                 = 'Your Path' "path to save your file
                DATA_SHEET_NAME           = V_SHEET_NAME
           TABLES
                DATA_TAB                  = TLX
           EXCEPTIONS
                FILE_NOT_EXIST            = 1
                FILENAME_EXPECTED         = 2
                COMMUNICATION_ERROR       = 3
                OLE_OBJECT_METHOD_ERROR   = 4
                OLE_OBJECT_PROPERTY_ERROR = 5
                INVALID_FILENAME          = 6
                INVALID_PIVOT_FIELDS      = 7
                DOWNLOAD_PROBLEM          = 8
                OTHERS                    = 9.
      IF SY-SUBRC NE 0.
        WRITE:/ 'ERROR OPENING EXCEL'.
      ENDIF.
    ELSE.
      WRITE:/ 'ERROR OR NO DATA'.
    ENDIF.

  • Alv report into excel file.

    Hello experts,
    I have alv report , and i want to export this alv to excel file, how can i do this ?
    Thanks for your help.
    Avi.

    Hi Avi,
    U can download to any format by using ctrlshiftF9 or using the button to 'Local File'. Then  apopup appears as:
    In which format should the list
    be saved ?
    And some radio buttons. U select the 'SPreadsheet' option for excel.
    And click enter.Then it will prompt for the Directory and filename for saving.
    Keerthi

  • Exporting Alv report to excel in forground & background.....

    Hello Experts,
    I need to schedule ALV report This has to be sheduled daily at 11.00 PM and the data should appear same as the ALV report sructure.if possible please provide me teh code.
    Thanks alot in advance..
    Thanks,,,
    Santosh..........
    Moderator message: "spec dumping", please work yourself first on your requirement.
    Edited by: Thomas Zloch on Jul 7, 2011 9:17 AM

    Hi,
    Here's my suggestion: Install OpenOffice.org and ask SAP to deliver good integration with OpenOffice.org.
    Alternative suggestion: re-install SAP Gui on the PC where the integration is not working. If that does not help, re-install Microsoft Office as well.
    Here's my comment: I think you should ask this question in a different forum, e.g. in the Duet forum. That may not be the correct forum either, but as it is a Microsoft/SAP integration technology forum, someone there may know the solution.
    Regards,
    Raj.

  • Fetch excel file from app. server using open dataset...

    Hello Experts,
    Our functional consultant is asking me if it possible to get an excel file from the
    application server file using OPEN dataset and in background mode? If yes, Please tell me on how to do this.
    Thank you guys and take care!

    Hi Viraylab,
    to download this the procedure:
    you can use the FM 'EXCEL_OLE_STANDARD_DAT ' for this purpose.
    this FM 'EXCEL_OLE_STANDARD_DAT' can be used to start Excel with a new sheet and transfer data from an internal table to the sheet.
    Here are some of the parameters:
    file_name: Name and path of the Excel worksheet file e.g. ?C:TEMPZTEST?
    data_tab: Name of the internal table that should be uploaded to Exvcel
    fieldnames: Internal tabel with column headers
    How to build the field names table:
    data: begin of i_fieldnames occurs 20,
    field(60), end of i_fieldnames.
    i_fieldnames-field = ?This is column 1?. append i_fieldnames-field.
    i_fieldnames-field = ?This is column 2?. append i_fieldnames-field.
    to upload follow this:
    OPEN DATASET dsn FOR INPUT IN BINARY MODE.
    DO.
    READ DATASET dsn INTO itab-field.
    IF sy-subrc = 0.
    APPEND itab.
    ELSE.
    EXIT.
    ENDIF.
    ENDDO.
    [/code]Rob
    or Try this function module.
    FILE_READ_AND_CONVERT_SAP_DATA
    pass 'XLS' to I_FILEFORMAT..
    Dont forgot to Reward me points .....All the very best....
    Regards,
    Sreenivasa sarma K.

  • Problem in alv report coumn header in the background while using salv

    Hi  all,
            now i am working on  alv report for this i have used salv i mean oops alv ,So here i am facing one issue while executing the report  in background
            the report column headers are not displaying properly as it is displaying in front end.
           In the back ground it is always displaying column header as data element field label short text. i have written a code to pick the long text
           but it is working fine if run the report in the frontend where as in the backgroiund it is always displaying short text but it is wrong.
    here i am attaching the output screen shots in front end and background.

    Hi Satish,
    I have tried this scenario with Reuse ALV grid 1st i found the same issue as u said in background job,
    then i set in field catalog as,
    wa_fcat-ddictxt = 'L'. Now its working fine. L stands for long text.
    Before...
    After...
    For LVC u can try the below fields in fieldcatlog.
    COLDDICTXT = 'L'.
    SELDDICTXT = 'L'

  • Reg: Download report into Excel file

    Hi All,
    While downloading the ALV report into excel file(System -> List -> Save -> Local file) or (List -> Export -> Local file), i cannot download full report in to excel. Even though the report contains just 200 rows(I can able to download about 90 lines).
    Some reports can able to download all the data, even the report is very big. Currently I am blind to solve, anyone can help me to solve this issue.
    Thanks in advance.

    The most elegant way of downloading ALV display data to EXCEL is displaying the excel in the SAP GUI screen itself.  Select "Excel in Place" and then save it from there. Before that you need to let the VB script of SAP know as trusted macro. This is done by opening a blank excel file then go to Tools > options > Security > Macro Security > Trusted Publishers (tab) > (check) Trust access to Visual Basic Project.  This activation is one time activation. Once you do this you can see ALV display exactly like in normal ALV with all the colors fields etc.

  • ALV Output to Excel file

    Hi All,
    I am downloading the ALV output to Excel file.I am making use of  LIST--->EXPORT--->SPREADSHEET option.
    My list is having Header, Footer, sub totals and totals.When i transfer the list i am facing following problems
    1.Even i am getting the empty columns betweeen my output.
    2.In the Place of sub totals i am getting astericks
    3.On the top of the records downloaded,"DYNAMIC LIST DISPLAY" is found.I want to avoid this text on the top
    Thanks,
    Ravee...

    Hello Vinod,
    1.I am getting the empty columns betweeen my output.
    I am having 16 columns in the ALV output,but i got 19 columns in my excel file.
    2.In the Place of sub totals i am getting astericks.
    Generally there is no possibility to download the sub totals.i am using LIST->EXPORT->SPREADSHEET.
                     I am having the sub totals in my output.
    *You would have noticed the' * ' for sub total and ' ** ' for grand totals values.*These sub total & total values are not downloaded but these asterisks are carried to excel file.
    3.On the top of the records downloaded,"DYNAMIC LIST DISPLAY" is found.I want to avoid this text on the top.
    I am using the application tool bar icon only.Still i am getting the same.
    Thanks,
    Ravee...

  • How to send ALV Report in excel format from SAP

    Hi Gurus,
    We are using SAP 4.7 and using different SAP reports.Now I want to send SAP ALV report in excel format directly from SAP in background.Now we send these reports in background weekly by using autimetic scheduling but this is PDF format.Now I want to change this pdf format to excel format.In SCOT T.Code I am able to find any excel format.Please help me out.
    I am waiting for your reply.
    Advance Thanks
    Nirmal

    Hi Nirmal,
    I have done the same in my previous organisation.For this particular solution you need to ask your basis guys to upgrade the support package so that BCS classes could be available in the system.
    API interafces five some problem with attachemnts and SAP has recommended to use BCS classes.
    Currently BCS classes won't be availbale in 4.7.
    Once the BCS classes are available
    use below code
       CONSTANTS:
        lc_tab          TYPE c VALUE cl_bcs_convert=>gc_tab,
        lc_crlf         TYPE c VALUE cl_bcs_convert=>gc_crlf,
       lc_codepage     TYPE abap_encod VALUE '4103',
    data :
       lv_string      TYPE string,
       binary_content TYPE solix_tab,
       size           TYPE so_obj_len,
       *" Set Heading of Excel File
      CONCATENATE 'Employee DATA'
                   lc_crlf lc_crlf
                   INTO lv_string.
       *" Set Header for Excel Fields
      CONCATENATE lv_string
                  lc_header1 lc_tab
                  lc_header2 lc_tab
                  lc_header3 lc_tab
                  lc_header4 lc_tab
                  lc_header5 lc_tab
                  lc_header6 lc_tab
                  lc_header7 lc_tab
                  lc_header8 lc_tab
                  lc_header9 lc_tab
                  lc_header10 lc_crlf
                  INTO lv_string.
    "lc_header1 to 10 could be your field headers
       "Move Internal table data
      LOOP AT gt_final1 INTO gwa_final1.
        CONCATENATE lv_string
                    gwa_final1-field1     lc_tab
                    gwa_final1-field2      lc_tab
                    gwa_final1-field3    lc_crlf
                    INTO lv_string.
      ENDLOOP.
       *" convert the text string into UTF-16LE binary data including
    *" byte-order-mark. Mircosoft Excel prefers these settings
    *" all this is done by new class cl_bcs_convert (see note 1151257)
      TRY.
          cl_bcs_convert=>string_to_solix(
            EXPORTING
              iv_string   = lv_string
              iv_codepage = lc_codepage  "suitable for MS Excel, leave empty
              iv_add_bom  = abap_true     "for other doc types
            IMPORTING
              et_solix  = binary_content
              ev_size   = size ).
        CATCH cx_bcs.
          MESSAGE e445(so).
      ENDTRY.
      TRY.
    *" create persistent send request
          send_request = cl_bcs=>create_persistent( ).
          document = cl_document_bcs=>create_document(
            i_type    = lc_doc
            i_text    = main_text
            i_subject = lc_sub  ).     
          document->add_attachment(
            i_attachment_type    = lc_attach                    "#EC NOTEXT
            i_attachment_subject = lc_sub                       "#EC NOTEXT
            i_attachment_size    = size
            i_att_content_hex    = binary_content ).
       send_request->set_document( document ).
       recipient = cl_cam_address_bcs=>create_internet_address( email ).
       CALL METHOD send_request->add_recipient
              EXPORTING
                i_recipient = recipient.
       IF recipient IS NOT INITIAL.
            sent_to_all = send_request->send( i_with_error_screen = abap_true ).
            COMMIT WORK.
    *        MESSAGE text-014 TYPE gc_succ  .
          ENDIF.
        CATCH cx_bcs INTO bcs_exception.
          MESSAGE i865(so) WITH bcs_exception->error_type.
      ENDTRY.
    For BCS decalartion u can go to se 38 and see program BCS_EXAMPLE_1 to BCS_EXAMPLE_7.
    Rewrads if helpful.
    Cheers
    Ramesh Bhatt

  • Download ALV report to excel sheet

    halo fellow SAPiens,
    i want to download my alv report into excel sheet...........for tht i used UGI_DOWNLOAD........here if i use the file type as 'ASC' all the leading zeros of numeric values are removed and date format is "yyyy/mm/dd".......
    i need the leading zeros and date format in "dd/mmyyy"
    when i use file type 'DBF' i get the leading zeros but my date is replaced by '#####.............wht shld i do...........

    To get the leading zeros to come, append an apostrophe to the start of each field that has the leading zeros as shown
    loop at itab.
    concatenate '''' itab-field1 into itab-field1.
    modify itab.
    endloop.
    note that
    1. This sometimes doesnt show correctly in excel and you may have to double click on the cell to prevent the apostrophe from displaying in the sheet
    2. You field needs to have an extra character to add the apostrophe

  • How to convert ALV report to Excel ??

    Hi,
    My requirement is to show ALV report in the excel .
    I have 2 radio buttons in Selection screen :
    1)  ALV  format                           2) Excel.
    If excel is selected then user will give a path : C :\newexcelreport.xls
    I knew that there is a way to download report through ALV report using download into local file. But the requirement is to create a report in Excel same like ALV report .
    I tried using GUI_Download . But it is displaying some fields wrongly, ex : Date , Time, without header .
    Date is showing year month date format in the excel .
    time is showing in a numeric format.
    But the ALV report is showing correct report . When I download into local then the report is showing correct results .
    Is there any function module to download exact ALV report into excel .??
    Thanks & Regards,
    Varma

    Use the FM - ALV_XXL_CALL. here is the sample -
    REPORT  ZSKC_ALV_XXL.
    TYPE-POOLS : KKBLO.
    DATA : ITAB LIKE T100 OCCURS 0,
           T_FCAT_LVC TYPE LVC_S_FCAT OCCURS 0 WITH HEADER LINE,
           T_FCAT_KKB TYPE KKBLO_T_FIELDCAT.
    START-OF-SELECTION.
    Get data.
      SELECT * UP TO 20 ROWS
      FROM   T100
      INTO   TABLE ITAB
      WHERE  SPRSL = SY-LANGU.
      CHECK SY-SUBRC EQ 0.
    Create the field catalog.
      CALL FUNCTION 'LVC_FIELDCATALOG_MERGE'
       EXPORTING
          I_STRUCTURE_NAME             = 'T100'
        CHANGING
          CT_FIELDCAT                  = T_FCAT_LVC[]
        EXCEPTIONS
          INCONSISTENT_INTERFACE       = 1
          PROGRAM_ERROR                = 2
          OTHERS                       = 3.
      CHECK SY-SUBRC EQ 0.
    make sure you pass the correct internal table name in the field catalog.
      t_fcat_lvC-tabname = 'ITAB'.
      MODIFY T_FCAT_LVC TRANSPORTING TABNAME WHERE TABNAME NE SPACE.
    Transfer to KKBLO format.
      CALL FUNCTION 'LVC_TRANSFER_TO_KKBLO'
        EXPORTING
          IT_FIELDCAT_LVC                 = T_FCAT_LVC[]
        IMPORTING
          ET_FIELDCAT_KKBLO               = T_FCAT_KKB
       EXCEPTIONS
         IT_DATA_MISSING                 = 1
         IT_FIELDCAT_LVC_MISSING         = 2
         OTHERS                          = 3.
      CHECK SY-SUBRC EQ 0.
    Call XXL.
      CALL FUNCTION 'ALV_XXL_CALL'
        EXPORTING
          I_TABNAME                    = 'ITAB'
          IT_FIELDCAT                  = T_FCAT_KKB
        TABLES
          IT_OUTTAB                    = ITAB[]
        EXCEPTIONS
          FATAL_ERROR                  = 1
          NO_DISPLAY_POSSIBLE          = 2
          OTHERS                       = 3.
      IF SY-SUBRC <> 0.
      ENDIF.

  • How to convert alv list into excel file?

    Hi Experts,
            i have created one report for Due Date Analysis.
    Now My output is displaying in ALV list. But I need to convert the data which in alv list into Excel File. then only i have to send the Excel File to the Customer Thro Email.
         So i need the Function Module to Convert the Data into Excel File.
    Thanks,
    Neptune.M

    Hi,
      U can use function module gui_download.
      CALL FUNCTION 'GUI_DOWNLOAD'
         EXPORTING
        BIN_FILESIZE       =
          filename           = 'C:\Transportaionlane.XLS'
          filetype                       = 'DAT'
        WRITE_FIELD_SEPARATOR           = ' '
        HEADER                          = '00'
        TABLES
          ata_tab                       = t_trans_lane_dis[]
           OTHERS                          = 22
    if u want with header then pass the header.
    regards
    Ahasan

Maybe you are looking for

  • Error installing CR2008 SP3 FP3.2 and/or FP3.3

    I have installed 2008 SP3 and FP3.1 sucessfully on several machines and am now trying to isntall FP3.2 or FP3.3, but both error during install: FP3.2 ===== Error 1311. Source file not found: C:\DOCUME1\JOHNST1\LOCALS~1\Temp\package\webform v.cab. Ver

  • My MacBook Pro won't wake up, how do I wake it?

    My computer has been bouncing out of iPhoto- I've had to restart my computer a few times today.  In the past it would sometimes take a long time to wake up- I would press the brightness key or track pad and it would wake up.  Now it is on but I canno

  • Is there a PHP variable that will fetch the TITLE of the file?

    I learned (thanks to David Powers) that you can use $_SERVER['PHP_SELF'] to refer to your current URL, which is useful in situations like putting a "Share on Facebook" button on your page. However, some of these social networking sites allow you to a

  • Download Solaris 8 7/01

    Hello, I want to download Solaris 8 7/01. Can anybody provide me with the link. -Mallik

  • Color of disabled textfiled text

    Hi, This is probably a simple one but I cant find an answer anyhwere. How do you change the color of the text in a disabled textfield from thet gray colour. Thanks John Cleary.