<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic excel sheet in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679079#M886003</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi i am in the process of learning abap and i wanted to know how data from an excel sheet be displayed in a report. can anybody please help me with this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 16 Apr 2008 20:18:55 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-04-16T20:18:55Z</dc:date>
    <item>
      <title>excel sheet</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679079#M886003</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi i am in the process of learning abap and i wanted to know how data from an excel sheet be displayed in a report. can anybody please help me with this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 16 Apr 2008 20:18:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679079#M886003</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-16T20:18:55Z</dc:date>
    </item>
    <item>
      <title>Re: excel sheet</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679080#M886004</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please go though the following link where you will get the answer.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[&lt;A class="jive_macro jive_macro_thread" href="https://community.sap.com/" __jive_macro_name="thread" modifiedtitle="true" __default_attr="173351"&gt;&lt;/A&gt;;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 16 Apr 2008 20:22:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679080#M886004</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-16T20:22:59Z</dc:date>
    </item>
    <item>
      <title>Re: excel sheet</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679081#M886005</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi ,&lt;/P&gt;&lt;P&gt;Please some more points on your question . &lt;/P&gt;&lt;P&gt;There several function module ,by  using that u can get excel data into innternal table and you can display or map to satndard transaction(bdc) etc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The function modules used to read local files:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Text_convert_xls_to_sap                     for Xls files&lt;/P&gt;&lt;P&gt; Alsm_excel_to_internal_table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The function modules to create local files :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    Sap_convert_to_xls_format&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reward if useful&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Jagadeesh.G&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Apr 2008 05:11:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679081#M886005</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-17T05:11:29Z</dc:date>
    </item>
    <item>
      <title>Re: excel sheet</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679082#M886006</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;but the excel sheet first row has to a definition of the coloum.if not it will leave the first record.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; CALL FUNCTION 'TEXT_CONVERT_XLS_TO_SAP'       " to upload from excel&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    I_FIELD_SEPERATOR        =&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      i_line_header                      =  'X'&lt;/P&gt;&lt;P&gt;      i_tab_raw_data                    =  it_raw       " WORK TABLE&lt;/P&gt;&lt;P&gt;      i_filename                            =  zfilenam&lt;/P&gt;&lt;P&gt;    TABLES&lt;/P&gt;&lt;P&gt;      i_tab_converted_data              = it_datatab[]&lt;/P&gt;&lt;P&gt;   EXCEPTIONS&lt;/P&gt;&lt;P&gt;      conversion_failed        = 1&lt;/P&gt;&lt;P&gt;      OTHERS                   = 2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno&lt;/P&gt;&lt;P&gt;            WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reward me if useful  .&lt;/P&gt;&lt;P&gt;don't forget.&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;  vinoth.v&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Apr 2008 06:15:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679082#M886006</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-17T06:15:20Z</dc:date>
    </item>
    <item>
      <title>Re: excel sheet</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679083#M886007</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;but the excel sheet first row has to a definition of the coloum.if not it will leave the first record.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use this code u will get it in the internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TYPE-POOLS: truxs.&lt;/P&gt;&lt;P&gt;DATA: it_raw TYPE truxs_t_text_data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: IT_ERROR LIKE BDCMSGCOLL OCCURS 0 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; CALL FUNCTION 'TEXT_CONVERT_XLS_TO_SAP'       " to upload from excel&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    I_FIELD_SEPERATOR        =&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      i_line_header                      =  'X'&lt;/P&gt;&lt;P&gt;      i_tab_raw_data                    =  it_raw    " WORK TABLE&lt;/P&gt;&lt;P&gt;      i_filename                            =  zfilenam&lt;/P&gt;&lt;P&gt;    TABLES&lt;/P&gt;&lt;P&gt;      i_tab_converted_data              = it_datatab[]&lt;/P&gt;&lt;P&gt;   EXCEPTIONS&lt;/P&gt;&lt;P&gt;      conversion_failed        = 1&lt;/P&gt;&lt;P&gt;      OTHERS                   = 2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno&lt;/P&gt;&lt;P&gt;            WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reward me if useful  .&lt;/P&gt;&lt;P&gt;don't forget.&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;  vinoth.v&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Apr 2008 06:18:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679083#M886007</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-17T06:18:08Z</dc:date>
    </item>
    <item>
      <title>Re: excel sheet</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679084#M886008</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TEXT_CONVERT_XLS_TO_SAP &lt;/P&gt;&lt;P&gt;Using this Function modulw we convert the Excel data into a internal table, This is a normal Excel data upload Function module..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See the below thread for a Example program...&lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_message" href="https://community.sap.com/" __jive_macro_name="message" modifiedtitle="true" __default_attr="2442134"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sapdevelopment.co.uk/file/file_upexcel.htm" target="test_blank"&gt;http://www.sapdevelopment.co.uk/file/file_upexcel.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Alsm_excel_to_internal_table&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This function module uploads data from excel to internal table,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check this sample code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TYPE-POOLS truxs.&lt;/P&gt;&lt;P&gt;TABLES:zmatnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA : itab LIKE alsmex_tabline OCCURS 0 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA row LIKE alsmex_tabline-row.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : g_matnr like mara-matnr.&lt;/P&gt;&lt;P&gt;data : count type i.&lt;/P&gt;&lt;P&gt;data : itab_count type i.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : gi_final like zmatnr occurs 0 with header line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*data : begin of gi_final occurs 0,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mat_old like mara-matnr, &lt;/P&gt;&lt;P&gt;mat_new like mara-matnr, &lt;/P&gt;&lt;P&gt;end of gi_final. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;***********************&lt;STRONG&gt;Selection Screen&lt;/STRONG&gt;*************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.&lt;/P&gt;&lt;P&gt;PARAMETER : pfname LIKE rlgrap-filename OBLIGATORY.&lt;/P&gt;&lt;P&gt;select-options : records for count.&lt;/P&gt;&lt;P&gt;SELECTION-SCREEN END OF BLOCK b1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*******************************************************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*********************&lt;STRONG&gt;At Selection Screen&lt;/STRONG&gt;*************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT SELECTION-SCREEN ON VALUE-REQUEST FOR pfname.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PERFORM search.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*******************************************************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;perform process.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;form process.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;filename = pfname&lt;/P&gt;&lt;P&gt;i_begin_col = 1&lt;/P&gt;&lt;P&gt;i_begin_row = 2&lt;/P&gt;&lt;P&gt;i_end_col = 12&lt;/P&gt;&lt;P&gt;i_end_row = 65000&lt;/P&gt;&lt;P&gt;TABLES&lt;/P&gt;&lt;P&gt;intern = itab&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;inconsistent_parameters = 1&lt;/P&gt;&lt;P&gt;upload_ole = 2&lt;/P&gt;&lt;P&gt;OTHERS = 3.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF sy-subrc 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO &lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. &lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;describe table itab lines itab_count.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;row = 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if itab-row row.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;append gi_final.&lt;/P&gt;&lt;P&gt;clear gi_final.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;case itab-col.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when '1'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLEAR G_MATNR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;gi_final-OLD_MATNR = itab-value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CONCATENATE 'NEW' gi_final-old_matnr INTO itab-value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;gi_final-new_MATNR = itab-value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endcase.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;row = itab-row.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;append gi_final.&lt;/P&gt;&lt;P&gt;clear gi_final.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'PROGRESS_INDICATOR' &lt;/P&gt;&lt;P&gt;EXPORTING &lt;/P&gt;&lt;P&gt;I_TEXT = 'File Has Been Successfully Uploaded from Workstation ' . &lt;/P&gt;&lt;P&gt;if not gi_final[] is initial.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if not records-low is initial .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if not records-high is initial.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;records-high = records-high + 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DESCRIBE TABLE gi_final LINES count.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF records-high &amp;lt; count.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DELETE gi_final FROM records-high TO count.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF records-low &amp;lt;&amp;gt; 1.&lt;/P&gt;&lt;P&gt;IF records-low 0.&lt;/P&gt;&lt;P&gt;DELETE gi_final FROM 1 TO records-low.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF NOT GI_FINAL[] IS INITIAL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'PROGRESS_INDICATOR'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;I_TEXT = 'Processing zmatnr table'&lt;/P&gt;&lt;P&gt;I_OUTPUT_IMMEDIATELY = 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if itab_count count. &lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;message i000 with 'records are not matching'. &lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;exit. &lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;else. &lt;/P&gt;&lt;P&gt;modify zmatnr from table gi_final.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;message i000 with 'data base table modified successfully'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endif. &lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endform.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;----&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;*&amp;amp; Form search&lt;/P&gt;&lt;P&gt;&amp;amp;----&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;text &lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="---------------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--&amp;gt; p1 text &lt;/P&gt;&lt;P&gt;&amp;lt;-- p2 text &lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="---------------------------------------------------------------------" /&gt;&lt;P&gt;FORM search .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'KD_GET_FILENAME_ON_F4'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;static = 'X'&lt;/P&gt;&lt;P&gt;CHANGING&lt;/P&gt;&lt;P&gt;file_name = pfname.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM. " search&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sap_convert_to_xls_format&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Download internal table data to Excel sheet.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function 'SAP_CONVERT_TO_XLS_FORMAT'&lt;/P&gt;&lt;P&gt;exporting&lt;/P&gt;&lt;P&gt;i_field_seperator = '#' "Field seprator in internal table&lt;/P&gt;&lt;P&gt;i_line_header = 'X'&lt;/P&gt;&lt;P&gt;i_filename = 'C:\kk.xls' &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I_APPL_KEEP = ' ' &lt;/P&gt;&lt;P&gt;tables&lt;/P&gt;&lt;P&gt;i_tab_sap_data = gt_itab "Internal table data&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CHANGING &lt;/P&gt;&lt;P&gt;I_TAB_CONVERTED_DATA = &lt;/P&gt;&lt;P&gt;exceptions&lt;/P&gt;&lt;P&gt;conversion_failed = 1&lt;/P&gt;&lt;P&gt;others = 2&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Raj.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Apr 2008 06:27:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679084#M886008</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-17T06:27:43Z</dc:date>
    </item>
    <item>
      <title>Re: excel sheet</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679085#M886009</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN __default_attr="blue" __jive_macro_name="color"&gt;
Hi Savitha,

We can use the Function module  TEXT_CONVERT_XLS_TO_SAP  to read the Excel file into the internal table. From this internal table you can fill the target internal table. 
 &lt;PRE&gt;&lt;CODE&gt;
  report  zvenkat-upload-xl  no standard page heading.
"----------------------------------------------------------------------
"Declarations.
"----------------------------------------------------------------------
"types
types:
      begin of t_bank_det,
        pernr(8)  type c,
        bnksa(4)  type c,
        zlsch(1)  type c,
        bkplz(10) type c,
        bkort(25) type c,
        bankn(18) type c,
      end of t_bank_det.
"work areas
data:
      w_bank_det type t_bank_det.
"internal tables
data:
      i_bank_det type table of t_bank_det.
"---------------------------------------------------------------------
" selection-screen
"----------------------------------------------------------------------
selection-screen begin of block b1 with frame title text_001.
parameters p_file type localfile.
selection-screen end of block b1.
*---------------------------------------------------------------------
"At selection-screen on value-request for p_file.
*---------------------------------------------------------------------
at selection-screen on value-request for p_file.
  perform f4_help.
*---------------------------------------------------------------------
  "Start-of-selection.
*---------------------------------------------------------------------
start-of-selection.
  perform upload_data.
*---------------------------------------------------------------------
  "End-of-selection.
*---------------------------------------------------------------------
end-of-selection.
  perform display_data.
*&amp;amp;---------------------------------------------------------------------*
  "Form  f4_help
*&amp;amp;---------------------------------------------------------------------*
form f4_help .
  data:
        l_file_name like  ibipparms-path  .

  call function 'F4_FILENAME'
    exporting
      program_name  = syst-cprog
      dynpro_number = syst-dynnr
      field_name    = 'P_FILE'
    importing
      file_name     = l_file_name.

  p_file = l_file_name.

endform.                                                    " f4_help
*---------------------------------------------------------------------*
"Form  upload_data
*---------------------------------------------------------------------*
form upload_data .
  type-pools:truxs.
  data:li_tab_raw_data type  truxs_t_text_data.
  data:l_filename      like  rlgrap-filename.

  l_filename = p_file.
  call function 'TEXT_CONVERT_XLS_TO_SAP'
    exporting
      i_tab_raw_data       = li_tab_raw_data
      i_filename           = l_filename
    tables
      i_tab_converted_data = i_bank_det
    exceptions
      conversion_failed    = 1
      others               = 2.
  if sy-subrc &amp;lt;&amp;gt; 0.
    message id sy-msgid type sy-msgty number sy-msgno
            with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
  endif.

endform.                    " upload_data
*---------------------------------------------------------------------*
" Form  display_data
*---------------------------------------------------------------------*
form display_data .
  data: char100 type char100.
  loop at i_bank_det into w_bank_det .
    if sy-tabix = 1.
      write w_bank_det.
      write / '------------------------------------------------------------'.
    else.
      write / w_bank_det.
    endif.
  endloop.

endform.                    " display_data 
&lt;/CODE&gt;&lt;/PRE&gt;
I hope that it helps u .

Regards,
Venkat.O
&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Apr 2008 07:03:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679085#M886009</guid>
      <dc:creator>venkat_o</dc:creator>
      <dc:date>2008-04-17T07:03:51Z</dc:date>
    </item>
    <item>
      <title>Re: excel sheet</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679086#M886010</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi!!&lt;/P&gt;&lt;P&gt;Try this code...&lt;/P&gt;&lt;P&gt;it works..n let me know if u face any difficulty!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This code uploads excel file from presentation layer(ur local PC)&lt;/P&gt;&lt;P&gt;and u can see the output in the form of report.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TYPES:BEGIN OF ty_itab ,&lt;/P&gt;&lt;P&gt;      objecttype TYPE string,&lt;/P&gt;&lt;P&gt;      objectname TYPE string,&lt;/P&gt;&lt;P&gt;      END OF ty_itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA:&lt;/P&gt;&lt;P&gt;          count TYPE i,&lt;/P&gt;&lt;P&gt;          file TYPE ibipparms-path,&lt;/P&gt;&lt;P&gt;          iexcel TYPE TABLE OF alsmex_tabline ,&lt;/P&gt;&lt;P&gt;          wa_itab TYPE ty_itab,&lt;/P&gt;&lt;P&gt;          itab type standard table of ty_itab,&lt;/P&gt;&lt;P&gt;          wa_iexcel TYPE alsmex_tabline.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;field-symbols : &amp;lt;fs&amp;gt; type string.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Calling function module to get file path from PC&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'F4_FILENAME'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;    program_name  = syst-cprog&lt;/P&gt;&lt;P&gt;    dynpro_number = syst-dynnr&lt;/P&gt;&lt;P&gt;  IMPORTING&lt;/P&gt;&lt;P&gt;    file_name     = file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Calling function module to upload excel sheet&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;    filename                = file&lt;/P&gt;&lt;P&gt;    i_begin_col             = 1&lt;/P&gt;&lt;P&gt;    i_begin_row             = 1&lt;/P&gt;&lt;P&gt;    i_end_col               = 2&lt;/P&gt;&lt;P&gt;    i_end_row               = 65000&lt;/P&gt;&lt;P&gt;  TABLES&lt;/P&gt;&lt;P&gt;    intern                  = iexcel&lt;/P&gt;&lt;P&gt;  EXCEPTIONS&lt;/P&gt;&lt;P&gt;    inconsistent_parameters = 1&lt;/P&gt;&lt;P&gt;    upload_ole              = 2&lt;/P&gt;&lt;P&gt;    OTHERS                  = 3.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;  WRITE :/15 'FILE NOT UPLOADED. INVALID FILE NAME OR PATH.' COLOR 6 .&lt;/P&gt;&lt;P&gt;  EXIT.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT iexcel INTO wa_iexcel.&lt;/P&gt;&lt;P&gt;  count  = count + 1.&lt;/P&gt;&lt;P&gt;  ASSIGN COMPONENT count OF STRUCTURE wa_itab TO  &amp;lt;fs&amp;gt;.&lt;/P&gt;&lt;P&gt;  &amp;lt;fs&amp;gt; = wa_iexcel-value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  AT END OF row.&lt;/P&gt;&lt;P&gt;    CLEAR count.&lt;/P&gt;&lt;P&gt;    APPEND wa_itab TO itab.&lt;/P&gt;&lt;P&gt;  ENDAT.&lt;/P&gt;&lt;P&gt;  CLEAR wa_iexcel.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;loop at itab into wa_itab.&lt;/P&gt;&lt;P&gt;Write : / wa_itab-objectname ,wa_itab-objecttype.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rewards points..if useful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Apr 2008 04:17:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/excel-sheet/m-p/3679086#M886010</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-18T04:17:26Z</dc:date>
    </item>
  </channel>
</rss>

