<?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 Re: alv in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954906#M392991</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;Please share the problem with us , what was the problem,


to change the headers

loop at it_fieldcat into wa_fieldcat.

   case wa_fieldcat-fieldname.

     when 'FIELD1'.
           wa_fieldcat-seltext_m = 'Field 1'.
           modify it_fieldcat from wa_fieldcat.
         when 'FIELD2'.
           wa_fieldcat-seltext_m = 'Field 2'.
          modify it_fieldcat from wa_fieldcat.
     endcase.

endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 02 Mar 2007 10:04:12 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-03-02T10:04:12Z</dc:date>
    <item>
      <title>alv</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954897#M392982</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;i have written a report using ALV but its giving me the following dump:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;An exception occurred. This exception is dealt with in more detail below        &lt;/P&gt;&lt;P&gt;. The exception, which is assigned to the class 'CX_SY_READ_SRC_LINE_TOO_LONG'  &lt;/P&gt;&lt;P&gt; was neither                                                                    &lt;/P&gt;&lt;P&gt;caught nor passed along using a RAISING clause, in the procedure                &lt;/P&gt;&lt;P&gt; "K_KKB_FIELDCAT_MERGE" "(FUNCTION)"                                            &lt;/P&gt;&lt;P&gt;.                                                                                &lt;/P&gt;&lt;P&gt;Since the caller of the procedure could not have expected this exception        &lt;/P&gt;&lt;P&gt; to occur, the running program was terminated.                                  &lt;/P&gt;&lt;P&gt;The reason for the exception is:                                                &lt;/P&gt;&lt;P&gt;You tried to read the program "ZSEARCH_ZDIPCOPY" from the database. The READ    &lt;/P&gt;&lt;P&gt; REPORT                                                                         &lt;/P&gt;&lt;P&gt;statement allows you to copy a program's source code into an internal           &lt;/P&gt;&lt;P&gt;table. The lines of source code must not be longer than the width of the        &lt;/P&gt;&lt;P&gt; internal table. The internal table is 72 characters wide. The source           &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and here is the program&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT  zsearch_zdip LINE-SIZE 400 NO STANDARD PAGE HEADING.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TABLES: zdiplomatic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TYPE-POOLS: slis.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: gt_fieldcat TYPE slis_t_fieldcat_alv.&lt;/P&gt;&lt;P&gt;DATA: v_repid TYPE syrepid.&lt;/P&gt;&lt;P&gt;v_repid = sy-repid.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF itab_zdip OCCURS 0,&lt;/P&gt;&lt;P&gt;      rbtno             LIKE zdiplomatic-rbtno,     "rebate number&lt;/P&gt;&lt;P&gt;      clr_dat           LIKE zdiplomatic-clr_dat,   "date of importation&lt;/P&gt;&lt;P&gt;      exp_date          LIKE zdiplomatic-exp_date,  "expiry date&lt;/P&gt;&lt;P&gt;      name1             LIKE zdiplomatic-name1,     "full name&lt;/P&gt;&lt;P&gt;      fax               LIKE zdiplomatic-fax,       "zim diplomatic id number&lt;/P&gt;&lt;P&gt;      hse_num           LIKE zdiplomatic-hse_num,   "house number&lt;/P&gt;&lt;P&gt;      street            LIKE zdiplomatic-street,    "street&lt;/P&gt;&lt;P&gt;      city              LIKE zdiplomatic-city,      "city&lt;/P&gt;&lt;P&gt;      make              LIKE zdiplomatic-make,      "vehicle make&lt;/P&gt;&lt;P&gt;      model             LIKE zdiplomatic-model,     "vehicle model&lt;/P&gt;&lt;P&gt;      reg_num           LIKE zdiplomatic-reg_num,   "reg num&lt;/P&gt;&lt;P&gt;      chassis           LIKE zdiplomatic-chassis,   "chassis&lt;/P&gt;&lt;P&gt;      engine_snr        LIKE zdiplomatic-engine_snr,"engine number&lt;/P&gt;&lt;P&gt;      station           LIKE zdiplomatic-st_nam,    "station&lt;/P&gt;&lt;P&gt;      officer           LIKE zdiplomatic-officer,   "officer&lt;/P&gt;&lt;P&gt;      END OF itab_zdip.&lt;/P&gt;&lt;P&gt;DATA WA_zdip LIKE STANDARD TABLE OF itab_zdip WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TOP-OF-PAGE.&lt;/P&gt;&lt;P&gt;  FORMAT COLOR COL_NORMAL.&lt;/P&gt;&lt;P&gt;  WRITE: 'Z I M B A B W E   R E V E N U E   A U T H O R I T Y'.&lt;/P&gt;&lt;P&gt;  WRITE: / 'D I P L O M A T I C  R E B A T E   S E A R C H   R E S U L T S'.&lt;/P&gt;&lt;P&gt;  FORMAT COLOR OFF.&lt;/P&gt;&lt;P&gt;  ULINE.&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;  SELECTION-SCREEN BEGIN OF BLOCK bli WITH FRAME TITLE text-bli.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  SELECT-OPTIONS: name1 FOR zdiplomatic-name1,&lt;/P&gt;&lt;P&gt;                  clr_dat FOR zdiplomatic-clr_dat,&lt;/P&gt;&lt;P&gt;                  exp_date FOR zdiplomatic-exp_date,&lt;/P&gt;&lt;P&gt;                  fax FOR zdiplomatic-fax,&lt;/P&gt;&lt;P&gt;                  reg_num FOR zdiplomatic-reg_num,&lt;/P&gt;&lt;P&gt;                  chassis FOR zdiplomatic-chassis,&lt;/P&gt;&lt;P&gt;                  make FOR zdiplomatic-make,&lt;/P&gt;&lt;P&gt;                  model FOR zdiplomatic-model,&lt;/P&gt;&lt;P&gt;                  st_nam FOR zdiplomatic-st_nam,&lt;/P&gt;&lt;P&gt;                  officer FOR zdiplomatic-officer,&lt;/P&gt;&lt;P&gt;                  eng_snr FOR zdiplomatic-engine_snr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  SELECTION-SCREEN END OF BLOCK bli.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  SELECT  rbtno             "rebate number&lt;/P&gt;&lt;P&gt;          clr_dat           "date of importation&lt;/P&gt;&lt;P&gt;          exp_date          "expiry date&lt;/P&gt;&lt;P&gt;          name1             "full name&lt;/P&gt;&lt;P&gt;          fax               "zim diplomatic id number&lt;/P&gt;&lt;P&gt;          hse_num           "house number&lt;/P&gt;&lt;P&gt;          street            "street&lt;/P&gt;&lt;P&gt;          city              "city&lt;/P&gt;&lt;P&gt;          make              "vehicle make&lt;/P&gt;&lt;P&gt;          model             "vehicle model&lt;/P&gt;&lt;P&gt;          reg_num           "reg num&lt;/P&gt;&lt;P&gt;          chassis           "chassis&lt;/P&gt;&lt;P&gt;          engine_snr        "engine number&lt;/P&gt;&lt;P&gt;          st_nam            "station&lt;/P&gt;&lt;P&gt;          officer           "officer&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;         FROM zdiplomatic INTO CORRESPONDING FIELDS OF TABLE WA_zdip&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;         WHERE       name1 IN name1.&lt;/P&gt;&lt;P&gt;               &lt;/P&gt;&lt;P&gt;  IF sy-subrc NE 0.&lt;/P&gt;&lt;P&gt;    WRITE / 'No Information found for the corresponding selection criteria!' COLOR COL_NEGATIVE.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;i_program_name = v_repid&lt;/P&gt;&lt;P&gt;i_internal_tabname = 'ITAB_ZDIP'&lt;/P&gt;&lt;P&gt;i_inclname = v_repid&lt;/P&gt;&lt;P&gt;CHANGING&lt;/P&gt;&lt;P&gt;ct_fieldcat = gt_fieldcat.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Pass the program.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;v_repid = sy-repid.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;i_callback_program = v_repid&lt;/P&gt;&lt;P&gt;it_fieldcat = gt_fieldcat&lt;/P&gt;&lt;P&gt;TABLES&lt;/P&gt;&lt;P&gt;t_outtab = WA_zdip.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;what is wrong with the program?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2007 08:49:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954897#M392982</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-02T08:49:47Z</dc:date>
    </item>
    <item>
      <title>Re: alv</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954898#M392983</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You tried to read the program "ZSEARCH_ZDIP" from the database. The READ&lt;/P&gt;&lt;P&gt;REPORT&lt;/P&gt;&lt;P&gt;statement allows you to copy a program's source code into an internal&lt;/P&gt;&lt;P&gt;table. The lines of source code must not be longer than the width of the&lt;/P&gt;&lt;P&gt;internal table. The internal table is 72 characters wide.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this is the probelm in ur program...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the read report statement it can read a report line by line and stores that in the internal table line by line.. If any line contains more than 72 characters it goes for a dump..&lt;/P&gt;&lt;P&gt;so make sure that the all the lines in the source code of the program ZSEARCH_ZDIPCOPY should not exceed 72 chars..&lt;/P&gt;&lt;P&gt;( including the commenting lines also.. ).&lt;/P&gt;&lt;P&gt;in read report it uses a variable w_line(72) ... so it gives dump when more than 72 chars are there in ur line..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reward if it hepls u...&lt;/P&gt;&lt;P&gt;sai ramesh.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2007 08:54:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954898#M392983</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-02T08:54:19Z</dc:date>
    </item>
    <item>
      <title>Re: alv</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954899#M392984</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Willard,&lt;/P&gt;&lt;P&gt; Use TYPE instead of LIKE in your internal table field declarations.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ravi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2007 08:54:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954899#M392984</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-02T08:54:37Z</dc:date>
    </item>
    <item>
      <title>Re: alv</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954900#M392985</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;change the declaration &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: v_repid TYPE syrepid.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;to&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: v_repid &amp;lt;b&amp;gt;like  sy-repid&amp;lt;/b&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and also assign the below statement in INITIALIZATION only once , uhad assigned twice&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;INITIALIZATION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;v_repid = sy-repid.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2007 08:55:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954900#M392985</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-02T08:55:05Z</dc:date>
    </item>
    <item>
      <title>Re: alv</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954901#M392986</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;try moving the following code &lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Pass the program.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;v_repid = sy-repid.&lt;/P&gt;&lt;P&gt;before&lt;/P&gt;&lt;P&gt;'REUSE_ALV_FIELDCATALOG_MERGE'.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2007 08:56:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954901#M392986</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-02T08:56:49Z</dc:date>
    </item>
    <item>
      <title>Re: alv</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954902#M392987</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;is that working ..... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let me know if it solves ur problem...!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2007 09:02:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954902#M392987</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-02T09:02:00Z</dc:date>
    </item>
    <item>
      <title>Re: alv</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954903#M392988</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;always u maintain the source code is not more than 72 characters wide(for all Programs)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2007 09:18:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954903#M392988</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-02T09:18:52Z</dc:date>
    </item>
    <item>
      <title>Re: alv</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954904#M392989</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanx hey. it worked&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2007 09:53:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954904#M392989</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-02T09:53:36Z</dc:date>
    </item>
    <item>
      <title>Re: alv</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954905#M392990</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;how or where do i manipulate column headers in ALV. i need to change the headers that coming out&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2007 10:00:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954905#M392990</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-02T10:00:28Z</dc:date>
    </item>
    <item>
      <title>Re: alv</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954906#M392991</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;Please share the problem with us , what was the problem,


to change the headers

loop at it_fieldcat into wa_fieldcat.

   case wa_fieldcat-fieldname.

     when 'FIELD1'.
           wa_fieldcat-seltext_m = 'Field 1'.
           modify it_fieldcat from wa_fieldcat.
         when 'FIELD2'.
           wa_fieldcat-seltext_m = 'Field 2'.
          modify it_fieldcat from wa_fieldcat.
     endcase.

endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2007 10:04:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv/m-p/1954906#M392991</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-02T10:04:12Z</dc:date>
    </item>
  </channel>
</rss>

