<?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: interactive report in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536150#M244595</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Venkat,&lt;/P&gt;&lt;P&gt;Try keyword GET CURSOR FIELD &amp;lt;FNAME&amp;gt; VALUE &amp;lt;FVAL&amp;gt;.&lt;/P&gt;&lt;P&gt;(FNAME AND FVAL Are to declared as string prior to this statement), now in variable fname, the field on which you clicked will be stored(for ex: itab-matnr) and in FVAL the value will be stored(R1234) and this key word u will be using in event AT LINE-SELECTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards:-&lt;/P&gt;&lt;P&gt;Santosh.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;P.S. Mark usefull answers&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 02 Aug 2006 06:08:48 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-08-02T06:08:48Z</dc:date>
    <item>
      <title>interactive report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536146#M244591</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i have a problem that,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when i am creating a interactive report normally we will display the details of basic list on a single field which is in vertical. but i need to display the details of secondary lists based on the basic list which is in horizontal.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;normal basic list like &lt;/P&gt;&lt;P&gt; matnr&lt;/P&gt;&lt;P&gt;1231321&lt;/P&gt;&lt;P&gt;121698&lt;/P&gt;&lt;P&gt;15987&lt;/P&gt;&lt;P&gt;1785121&lt;/P&gt;&lt;P&gt;and while double click on matnr we can get the secondary list.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But in my case basic list is like&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;matnr      quantity        date&lt;/P&gt;&lt;P&gt;135154      4564            02.08.2006&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;while double click on matnr OR any other field, i need to display the secondary list.    &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anyone give suggestion on this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;Venkat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Aug 2006 05:58:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536146#M244591</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-02T05:58:46Z</dc:date>
    </item>
    <item>
      <title>Re: interactive report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536147#M244592</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Just hide your matnr after your first basic list.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Like&lt;/P&gt;&lt;P&gt;Loop at itab.&lt;/P&gt;&lt;P&gt;*write your list&lt;/P&gt;&lt;P&gt;w_matnr = itab-matnr.&lt;/P&gt;&lt;P&gt;hide w_matnr.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;at line-selection.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;you have the value of the material of selected line in the w_matnr.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;so access your table &lt;/P&gt;&lt;P&gt;read table itab with key matnr = w_mantr.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;right data&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Aug 2006 06:02:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536147#M244592</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2006-08-02T06:02:15Z</dc:date>
    </item>
    <item>
      <title>Re: interactive report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536148#M244593</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;use.&lt;/P&gt;&lt;P&gt;AT LINE-SELECTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PERFORM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Aug 2006 06:02:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536148#M244593</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-02T06:02:54Z</dc:date>
    </item>
    <item>
      <title>Re: interactive report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536149#M244594</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Venkat,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If u want to write the basic list in the Vertical format then use the Write stmt like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Write:/ matnr,&lt;/P&gt;&lt;P&gt;      / MENGE,&lt;/P&gt;&lt;P&gt;      / ERDAT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If useful reward.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;vasanth&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Aug 2006 06:04:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536149#M244594</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-02T06:04:08Z</dc:date>
    </item>
    <item>
      <title>Re: interactive report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536150#M244595</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Venkat,&lt;/P&gt;&lt;P&gt;Try keyword GET CURSOR FIELD &amp;lt;FNAME&amp;gt; VALUE &amp;lt;FVAL&amp;gt;.&lt;/P&gt;&lt;P&gt;(FNAME AND FVAL Are to declared as string prior to this statement), now in variable fname, the field on which you clicked will be stored(for ex: itab-matnr) and in FVAL the value will be stored(R1234) and this key word u will be using in event AT LINE-SELECTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards:-&lt;/P&gt;&lt;P&gt;Santosh.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;P.S. Mark usefull answers&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Aug 2006 06:08:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536150#M244595</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-02T06:08:48Z</dc:date>
    </item>
    <item>
      <title>Re: interactive report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536151#M244596</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Venkat,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Display Secondary list like&lt;/P&gt;&lt;P&gt;Loop at&lt;/P&gt;&lt;P&gt;write:/ fields&lt;/P&gt;&lt;P&gt;Hide: matnr&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;At New Selection.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Read particular double click line values from list using&lt;/P&gt;&lt;P&gt;Read line sy-lilli value into l_line&lt;/P&gt;&lt;P&gt;based on l_line material value read the data from data base table and display the secondary list&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Aug 2006 06:16:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536151#M244596</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-02T06:16:20Z</dc:date>
    </item>
    <item>
      <title>Re: interactive report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536152#M244597</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Venkat,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try this code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tables : Mara.&lt;/P&gt;&lt;P&gt;DATA: index type i.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;***Select data from table here&lt;/P&gt;&lt;P&gt;***select * from mara where......&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    write/: mara-matnr .&lt;/P&gt;&lt;P&gt;    hide : mara-MATKL,&lt;/P&gt;&lt;P&gt;           mara-mtart,&lt;/P&gt;&lt;P&gt;           mara-MEINS.&lt;/P&gt;&lt;P&gt;   &lt;/P&gt;&lt;P&gt;***Endselect.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT line-selection.&lt;/P&gt;&lt;P&gt;write: mara-matkl, ' ' ,  mara-MEINS,' ' , mara-mtart.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;Pragya&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Aug 2006 06:17:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536152#M244597</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-02T06:17:29Z</dc:date>
    </item>
    <item>
      <title>Re: interactive report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536153#M244598</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Venkat ,&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;PRE&gt;&lt;CODE&gt;
REPORT  ztest.

*Consider  a scenario when the user asks for Material Details(Table : MARA )
*displayed in one List and based on the Material selected he wants the corresponding
*Storage Location Data for that Material (Table : MARD ).


TABLES : mara.
TYPES :  BEGIN OF tp_mara,
         matnr TYPE mara-matnr,
         mtart TYPE mara-mtart,
         mbrsh TYPE mara-mbrsh,
         matkl TYPE mara-matkl,
         END OF tp_mara.


TYPES : BEGIN OF tp_marc,
        matnr TYPE marc-matnr,
        werks TYPE marc-werks,
        pstat TYPE marc-pstat,
        ekgrp TYPE marc-ekgrp,
        dispr TYPE marc-dispr,
        END OF tp_marc.


TYPES : BEGIN OF tp_mard,
        matnr TYPE mard-matnr,
        werks TYPE mard-werks,
        lgort TYPE mard-lgort,
        lfgja TYPE mard-lfgja,
        labst TYPE mard-labst,
        umlme TYPE mard-umlme,
        END OF tp_mard.

DATA : t_mara TYPE STANDARD TABLE OF tp_mara,
       t_marc TYPE STANDARD TABLE OF tp_marc,
       t_mard TYPE STANDARD TABLE OF tp_mard,
       wa_mara TYPE tp_mara,
       wa_marc TYPE tp_marc,
       wa_mard TYPE tp_mard.
DATA : w_werks TYPE werks .



SELECTION-SCREEN BEGIN OF BLOCK blck1 WITH FRAME TITLE text-001.
SELECT-OPTIONS : s_matnr FOR mara-matnr.
PARAMETERS     : p_mtart TYPE mara-mtart .
SELECTION-SCREEN END OF BLOCK blck1.



START-OF-SELECTION.

*Collecting the material details form Table MARA

  SELECT matnr
         mtart
         mbrsh
         matkl
         FROM mara
         INTO TABLE t_mara
         UP TO 200 ROWS
         WHERE matnr IN s_matnr AND
               mtart EQ p_mtart.


END-OF-SELECTION.


*Now I am Dispalying the Material Details in the Primary List

  CLEAR wa_mara.
  LOOP AT t_mara INTO wa_mara.
    IF sy-tabix EQ 1.
      FORMAT INTENSIFIED ON.
      FORMAT COLOR COL_KEY.
      WRITE : /5(16)  'Material Number'.
      FORMAT COLOR COL_NORMAL.
      WRITE :          24(15) 'Material Type',
               40(18) 'Industry Sector',
               58(18) 'Material Group' .
    ENDIF.
    FORMAT INTENSIFIED OFF.
    FORMAT COLOR COL_KEY.
    WRITE : /5(16)   wa_mara-matnr.
    FORMAT COLOR COL_NORMAL.
    WRITE :  24(15)  wa_mara-mtart,
             40(18)  wa_mara-mbrsh,
             58(18)  wa_mara-matkl.


*You can assume some sort of buffer is created in the memory  and the values of
* wa_mara-matnr are put into it when you use the HIDE command

    HIDE wa_mara-matnr.


  ENDLOOP.


*Now when user Double clicks a line (AT LINE-SELECTION event is trigerred) and
*the line contents of the line selected and the contents buffered using
*command  interact and the value for the hidden variable is got into the variable
*refrenced using the HIDE command i.e..  wa_mara-matnr in our case

AT LINE-SELECTION.


  IF sy-lsind = 1.

    FORMAT INTENSIFIED ON.
    WRITE:     'Plant Data for Material  '  COLOR COL_NORMAL,
                35   wa_mara-matnr COLOR COL_TOTAL.

    REFRESH t_marc.

* Now I have the value of the Material in my hidden variable wa_mara-matnr
* Based on this I am selecting the Storage Location Data

    SELECT matnr
           werks
           pstat
           ekgrp
           dispr
           FROM marc
           INTO TABLE t_marc
           WHERE matnr = wa_mara-matnr.

    CLEAR wa_marc.
    FORMAT INTENSIFIED OFF.
    FORMAT COLOR COL_NORMAL.
    LOOP AT t_marc INTO wa_marc.

      IF sy-tabix EQ 1.

        FORMAT INTENSIFIED ON.
        FORMAT COLOR COL_NORMAL.
        WRITE :  /24(6)  'Plant',
                 30(22) 'Maintenance status',
                 52(20) 'Purchasing Group',
                 72(27)  'Material: MRP profile'.

      ENDIF.

      WRITE : /24(6)   wa_marc-werks,
               30(22)  wa_marc-pstat,
               52(20)  wa_marc-ekgrp,
               72(27) wa_marc-dispr.


      CLEAR wa_marc.

    ENDLOOP.

    SKIP 5.

    FORMAT INTENSIFIED ON.
    WRITE:     'Storage Data for Material  '  COLOR COL_NORMAL,
              35     wa_mara-matnr COLOR COL_TOTAL.
    REFRESH t_mard.
    SELECT matnr
           werks
           lgort
           lfgja
           labst
           umlme
           FROM mard
           INTO TABLE t_mard
           WHERE matnr = wa_mara-matnr.

    CLEAR wa_mard.
    FORMAT COLOR COL_NORMAL.


* Display the Storage Location Data in the Secondary List

    LOOP AT t_mard INTO wa_mard.

      IF sy-tabix EQ 1.

        FORMAT INTENSIFIED ON.
        FORMAT COLOR COL_NORMAL.
        WRITE :  /24(6)  'Plant',
                 30(20) 'Storage Location',
                 50(12) 'Fiscal Year',
                 62(15) 'Valuated stock',
                 77(20)    'Stock in transfer'.
      ENDIF.




      WRITE : /24(6)  wa_mard-werks,
               30(20) wa_mard-lgort,
               50(12)  wa_mard-lfgja,
               62(15) wa_mard-labst,
               77(20) wa_mard-labst.


    ENDLOOP.

  ENDIF.


&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;AS.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Aug 2006 06:19:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/interactive-report/m-p/1536153#M244598</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-02T06:19:02Z</dc:date>
    </item>
  </channel>
</rss>

