Hide statement

hi friends,
can we use a hide statement in  internal table  in interactive reports
is there any problem.
regards,
malleswari.

hi,
what do you mean by hide in internal table?
hide statement is used to store in interactive reports and used to capture the values which we click.
generally they are used as below.
loop at itab.
write: itab-f1.
write: itab-f2.
hide itab-f1.
endloop.
at line-selection.
select x from xyz into itab2 where f1 = itab-f1.
loop at itab2.
write itab2-x.
endloop.
here u are hiding the values itab-f1 and what ever value the user clicks is used in the select statment.
hope it helps.
santhosh

Similar Messages

  • Problem with HIDE statement

    Hi All,
    i have been working with an interactive report. while coding for the event AT LINE SELECTION i have used HIDE statement to capture the contents of the row on which click either on basic or secondary list. but the hide statment is not capturing the content of the record which i click. i have debugged the program, when the cursor comes to HIDE statement it is passing into some standard programs and still it is not holding the contents of the record on which i click.
    below is the coding, can anyone let me know where the coding went wrong.
    TABLES: VBAK,                       " Sales Document: Header Data
            VBAP,                       " Sales Document: Item Data
            VBKD,                       " Sales Document: Business Data
            VBEP.                       " Sales Document: Schedule Line Data
    TYPES BEGIN OF TY_VBAK.
            INCLUDE STRUCTURE VBAK.
    TYPES END OF TY_VBAK.
    TYPES BEGIN OF TY_VBAP.
            INCLUDE STRUCTURE VBAP.
    TYPES END OF TY_VBAP.
    TYPES BEGIN OF TY_VBKD.
            INCLUDE STRUCTURE VBKD.
    TYPES END OF TY_VBKD.
    TYPES BEGIN OF TY_VBEP.
            INCLUDE STRUCTURE VBEP.
    TYPES END OF TY_VBEP.
    DATA: IT_VBAK TYPE STANDARD TABLE OF TY_VBAK,
          WA_VBAK TYPE TY_VBAK,
          IT_VBAP TYPE STANDARD TABLE OF TY_VBAP,
          WA_VBAP TYPE TY_VBAP,
          IT_VBKD TYPE STANDARD TABLE OF TY_VBKD,
          WA_VBKD TYPE TY_VBKD,
          IT_VBEP TYPE STANDARD TABLE OF TY_VBEP,
          WA_VBEP TYPE TY_VBEP.
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
      SELECT-OPTIONS: S_VKORG FOR VBAK-VKORG,             " SALES ORGANIZATION
                      S_VTWEG FOR VBAK-VTWEG,             " DISTRIBUTION CHANNEL
                      S_SPART FOR VBAK-SPART,             " DIVISION
                      S_ERDAT FOR VBAK-ERDAT.             " OBJECT CREATED DATE
      PARAMETERS: P_ERNAM TYPE VBAK-ERNAM.                " OBJECT CREATED PERSON
    SELECTION-SCREEN END OF BLOCK B1.
    TOP-OF-PAGE.
      WRITE:/ 'THIS IS SALES DOCUMENT HEADER DATA'.
    TOP-OF-PAGE DURING LINE-SELECTION.
    IF SY-LSIND EQ 1.
      WRITE:/ 'THIS IS SALES DOCUMENT ITEM DETAILS'.
    ELSEIF SY-LSIND EQ 2.
      WRITE:/ 'THIS IS SALES DOCUMENT BUSINESS DATA'.
    ELSE.
      WRITE:/ 'THIS IS SALES DOCUMENT SCHEDULING LINE DATA'.
    ENDIF.
    START-OF-SELECTION.
    SELECT *
            FROM VBAK
            INTO TABLE IT_VBAK
            WHERE VKORG IN S_VKORG
            AND   VTWEG IN S_VTWEG
            AND   SPART IN S_SPART
            AND   ERDAT IN S_ERDAT
            AND   ERNAM EQ P_ERNAM.
      LOOP AT IT_VBAK INTO WA_VBAK.
    WRITE:/ WA_VBAK-VBELN HOTSPOT, WA_VBAK-ERNAM, WA_VBAK-VBTYP, WA_VBAK-AUART,
                WA_VBAK-SUBMI, WA_VBAK-VKORG, WA_VBAK-VTWEG, WA_VBAK-VKGRP,
                WA_VBAK-VKBUR, WA_VBAK-KNUMV, WA_VBAK-KTEXT, WA_VBAK-BSTNK,
                WA_VBAK-BSARK, WA_VBAK-BSTZD, WA_VBAK-KUNNR, WA_VBAK-KOSTL.
      HIDE: WA_VBAK-VBELN.
      ENDLOOP.
    AT LINE-SELECTION.
    IF SY-LSIND EQ 1.
        IF NOT IT_VBAK IS INITIAL.
        SELECT *
                FROM VBAP
                INTO TABLE IT_VBAP
                WHERE VBELN EQ WA_VBAK-VBELN.
      ENDIF.
      LOOP AT IT_VBAP INTO WA_VBAP.
    WRITE:/ WA_VBAP-VBELN HOTSPOT, WA_VBAP-POSNR, WA_VBAP-MATNR, WA_VBAP-MATWA,
                WA_VBAP-PMATN, WA_VBAP-CHARG, WA_VBAP-MATKL, WA_VBAP-ARKTX,
                WA_VBAP-PRODH, WA_VBAP-ZWERT, WA_VBAP-ZMENG, WA_VBAP-MEINS,
                WA_VBAP-ABDAT, WA_VBAP-ABSFZ, WA_VBAP-KDMAT, WA_VBAP-KBVER.
        HIDE: WA_VBAP-VBELN.
      ENDLOOP.
    ENDIF.
    IF SY-LSIND EQ 2.
      IF NOT IT_VBAP IS INITIAL.
        SELECT *
                FROM VBKD
                INTO TABLE IT_VBKD
                WHERE VBELN EQ WA_VBAP-VBELN.
      ENDIF.
      LOOP AT IT_VBKD INTO WA_VBKD.
    WRITE:/ WA_VBKD-VBELN HOTSPOT, WA_VBKD-POSNR, WA_VBKD-KONDA, WA_VBKD-KDGRP,
                  WA_VBKD-BZIRK, WA_VBKD-PLTYP, WA_VBKD-INCO2, WA_VBKD-KURRF,
                  WA_VBKD-VALDT, WA_VBKD-PRSDT, WA_VBKD-FKDAT, WA_VBKD-STCUR,
                  WA_VBKD-FPLNR, WA_VBKD-BSTDK, WA_VBKD-AKWAE, WA_VBKD-AKPRZ.
        HIDE: WA_VBKD-VBELN.
      ENDLOOP.
    ENDIF.
    IF SY-LSIND EQ 3.
      IF NOT IT_VBKD IS INITIAL.
        SELECT *
                FROM VBEP
                INTO TABLE IT_VBEP
                WHERE VBELN EQ WA_VBKD-VBELN.
      ENDIF.
      LOOP AT IT_VBEP INTO WA_VBEP.
    WRITE:/ WA_VBEP-VBELN HOTSPOT, WA_VBEP-POSNR, WA_VBEP-ETENR, WA_VBEP-ETTYP,
                  WA_VBEP-EDATU, WA_VBEP-EZEIT, WA_VBEP-WMENG, WA_VBEP-BMENG,
                  WA_VBEP-LMENG, WA_VBEP-MEINS, WA_VBEP-BDDAT, WA_VBEP-BDART,
                  WA_VBEP-VBELE, WA_VBEP-POSNE, WA_VBEP-ETENE, WA_VBEP-BSART.
      ENDLOOP.
    ENDIF.
    in the output iam getting the basic list and the subsequent secondary lists but in the secondary lists iam having the data of the last record of the basic list.
    let me know why the HIDE statement is not getting triggered.
    Thanks,
    BJR.

    Hi,
    Hide statement stores according to sy-linno.
    The Problem is with the empty fields in your Work area. When they are empty it goes for next line and 'write:/' statement will not trigger next line . so, the next work area prints on the same sy-lino which is already reserved for previous one .
    You can read Documentation in that
    HIDE <f>.
    This statement places the contents of the variable <f>
    for the current output line (system field SY-LINNO) into the HIDE area.
    The variable <f> must not necessarily appear on the current line.
    To make your program more readable,
    always place the HIDE statement directly after the output statement
    for the variable <f> or after the last output statement for the current line.
    You can try this piece of code for your understanding,
    DATA:
      w_hide LIKE sy-index.
      DO 20 TIMES.
       w_hide = sy-index.
        WRITE w_hide.
        NEW-LINE.
        HIDE w_hide.
      ENDDO.
    AT LINE-SELECTION.
      IF sy-lsind = 1.
        WRITE w_hide.
      ENDIF.
    Hope you understand.
    Regards,
    Raghava Channooru

  • Problem in using Field Symbols in HIDE statement

    Hi All,
    I am working in an Upgrade project ( from 4.6B to ECC 5.0 ). In a program I found few warnings on HIDE statement because they have used Field Symbols in HIDE statement.
    The warning is " HIDE on a field symbol is dangerous, but the formal parameter "" is not ".
    and the piece of code is
    SET EXTENDED CHECK OFF.
    HIDE: flg_pick_up, <s1>, <s2>, <s3>, <s4>, <s5>, z_feld_ind.
    CLEAR flg_pick_up.
    SET EXTENDED CHECK ON.
    all the field symbols are of type ANY. SO can any one help in removing those warnings.
    Please reply me as soon as possible.
    With Regards,
    Amarnath Singanamala

    Hi amarnath,
    1. Why do u want to remove
       the warning ?
    2. This warning (and not an error)
       is a GENUINE warning,
      which the system wants the user to make aware of.
    3. By doing some xyz,
      even if u may be able to hide the warning,
      the warning may be hidden (for display purpose only),
      but,
      the warning will still be there inside the system.
    4. I think u should ignore the warning,
      (if there are no other repurcussions).
    regards,
    amit m.

  • Hide statement not working

    Hi experts,
    i am using hide statement but it is not working..The problem with it is that after line selection the variable on which i have used hide is carrying the last value of internal table always..<< Removed >>
    Regards,
    Raman
    Edited by: Rob Burbank on Jun 30, 2009 10:41 AM

    I am sending a test program with same problem...iin this after line selection the field variable emp-name is displayin only last entry of internal table...
    *& Report  ZBASICX12
    REPORT  ZBASICX12.
    INITIALIZATION.
      DATA: BEGIN OF ITAB OCCURS 0,
            EMPID  TYPE ZTEMP-EMPID,
            EMPNAME TYPE ZTEMP-EMPNAME,
            END OF ITAB.
    START-OF-SELECTION.
      SELECT EMPID EMPNAME FROM ZTEMP INTO TABLE ITAB.
      SORT ITAB BY EMPID.
      LOOP AT ITAB.
        WRITE: / ITAB-EMPID HOTSPOT.
        HIDE ITAB-EMPID.
      ENDLOOP.
    END-OF-SELECTION.
    AT LINE-SELECTION.
      CASE SY-LSIND.
        WHEN 1.
          WRITE: ITAB-EMPNAME.
      ENDCASE.

  • HOW TO USE HIDE STATEMENT IN INTERACTIVE ALV.

    Hi Friends,
                  Actually i am writing the INTERACTIVE ALV.In this ALV i need to USE HIDE STATEMENT.
    This is an urgent requirement.
    Please anybody help me.
    Thanks&Regards
    Thummala Krishna Reddy.

    Hi,
    use the below code for Hide in ALV interactive report.
    use hotspot in fieldcatalog
    gwa_fieldcat-tabname   =  gc_bsik.
      gwa_fieldcat-fieldname =  gc_bukrs.
      gwa_fieldcat-outputlen =  gc_12.
      gwa_fieldcat-hotspot   =  gc_x.
      gwa_fieldcat-seltext_l =  text-016.
      APPEND gwa_fieldcat TO git_fieldcat.
      CLEAR gwa_fieldcat.
    and create dynamic subroutine like:
    FORM sub_user_command1 USING r_ucomm LIKE sy-ucomm
    rs_selfield TYPE slis_selfield.                             "#EC CALLED
    *Fi Documents-3rd level
      CASE r_ucomm.
        WHEN '&IC1'.
          CLEAR gwa_bsik3.
          READ TABLE git_bsik3 INTO gwa_bsik3 INDEX rs_selfield-tabindex.
          MOVE rs_selfield-value TO gwa_bsik3-lifnr.
          IF rs_selfield-fieldname EQ 'LIFNR'.
            PERFORM sub_build_fieldcatlog2.
            PERFORM sub_data_retrieval2.
            PERFORM sub_display_alv2.
          ENDIF.
      ENDCASE.
    ENDFORM.                    "sub_user_command1
    call the above user command in alv display like below code.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
          i_callback_program      = gv_repid
          i_callback_user_command = 'SUB_USER_COMMAND1'
          i_callback_top_of_page  = 'SUB_F_TOP_OF_PAGE'
          it_fieldcat             = git_fieldcat1[]
          i_save                  = gc_a
          it_events               = git_events
        TABLES
          t_outtab                = git_bsik3
        EXCEPTIONS
          OTHERS                  = 0.
      CLEAR : git_bsik3.
    pl let me know if you need any more info.
    Regards,
    Mahesh

  • Internal table name which hide statement uses

    Hi,
    To hide several variables, use chain HIDE statement.
    As soon as the user selects a line for which you stored HIDE fields, the system fills the variables in the program with the values stored.  A line can be selected.
    ¨      By an interactive event.
    For each interactive event, the HIDE fields of the line on which the cursor is positioned during the event are filled with the stored values.
    The HIDE area is a table, in which the system stores the names and values of all HIDE fields for each list and line number.  As soon as they are needed, the system reads the values from the table. 
    I want to know how can we find the name of that internal table.
    Regards,
    maqsood

    Hi,
    i think it is system defined.
    The HIDE Technique
    You use the HIDE technique while creating a list level to store line-specific information for later use. To do so, use the HIDE statement as follows:
    HIDE <f>.
    This statement places the contents of the variable <f> for the current output line (system field SY-LINNO) into the HIDE area. The variable <f> must not necessarily appear on the current line.
    To make your program more readable, always place the HIDE statement directly after the output statement for the variable <f> or after the last output statement for the current line.
    As soon as the user selects a line for which you stored HIDE fields, the system fills the variables in the program with the values stored. A line can be selected
    by an interactive event.
    For each interactive event, the HIDE fields of the line on which the cursor is positioned during the event are filled with the stored values.
    by the READ LINE statement.
    <b>You can think of the HIDE area as a table, in which the system stores the names and values of all HIDE fields for each list and line number. As soon as they are needed, the system reads the values from the table.</b>
    Thanks&Regards,
    Ruthra.R

  • Interactive report--hide statement?

    hi
    I am making an interactive report,but my hide statement is not working.my code is like:
    START-OF-SELECTION.
      SELECT matnr
             mtart
             matkl
      INTO CORRESPONDING FIELDS OF TABLE itab1
      FROM mara  WHERE matnr IN p_matnr.
      WRITE:/4 'Material No.' ,22 'Material Type' ,
             37 'Material Group'.
      WRITE:/ sy-uline.
      LOOP AT itab1.
        WRITE:/4 itab1-matnr ,20 sy-vline ,22 itab1-mtart ,
               35 sy-vline ,37 itab1-matkl,sy-uline.
        HIDE itab1-matnr.
      ENDLOOP.
    AT LINE-SELECTION.
      CASE sy-lsind.
        WHEN '1'.
          SELECT amatnr bmaktx INTO CORRESPONDING FIELDS OF TABLE itab2
          FROM ( mara AS a INNER JOIN makt AS b ON amatnr = bmatnr )
          WHERE a~matnr = itab1-matnr.
          WRITE:/ sy-uline.
          WRITE:/4 'Material No.' ,22 'Material Text'.
          WRITE:/ sy-uline.
          LOOP AT itab2.
            WRITE:/4 itab2-matnr ,20 sy-vline ,22 itab2-maktx,
                     sy-uline.
          ENDLOOP.
    here when my at line-selction is working,in select query,hide is not updated,its contains the last record value f itab1,where it should have value i selected from display.
    thus my seconday list is showing the value of last record of itab1 all time.
    please tell,how to make it working?
    vipin
    Edited by: Vipin on Jun 18, 2008 5:23 PM

    Hi,
    Check the example code , this will help you.
    REPORT demo_list_hide NO STANDARD PAGE HEADING.
    TABLES: spfli, sbook.
    DATA: num TYPE i,
    dat TYPE d.
    START-OF-SELECTION.
    num = 0.
    SET PF-STATUS 'FLIGHT'.
    GET spfli.
    num = num + 1.
    WRITE: / spfli-carrid, spfli-connid,
              spfli-cityfrom, spfli-cityto.HIDE: spfli-carrid, spfli-connid, num.
    END-OF-SELECTION.
    CLEAR num.
    TOP-OF-PAGE. WRITE 'List of Flights'.ULINE. WRITE 'CA CONN FROM TO'. ULINE.
    TOP-OF-PAGE DURING LINE-SELECTION.
    CASE sy-pfkey.
    WHEN 'BOOKING'.
    WRITE sy-lisel.
    ULINE.
    WHEN 'WIND'.
    WRITE: / 'Booking', sbook-bookid,'Date ', sbook-fldate.ULINE. ENDCASE.
    AT USER-COMMAND.
    CASE sy-ucomm.
    WHEN 'SELE'.
    IF num NE 0. SET PF-STATUS 'BOOKING'. CLEAR dat. SELECT * FROM sbook WHERE carrid = spfli-carridAND
    IF sbook-fldate NE dat.connid = spfli-connid. dat = sbook-fldate. SKIP. WRITE / sbook-fldate.POSITION 16.
    ELSE. NEW-LINE. POSITION 16.
    ENDIF.
    WRITE sbook-bookid.
    HIDE: sbook-bookid, sbook-fldate, sbook-custtype,
    sbook-smoker, sbook-luggweight, sbook-class.ENDSELECT. IF sy-subrc NE 0.
    WRITE / 'No bookings for this flight'.
    ENDIF.
    num = 0.
    CLEAR sbook-bookid.
    ENDIF.
    WHEN 'INFO'.
    IF NOT sbook-bookid IS INITIAL.
    SET PF-STATUS 'WIND'.
    SET TITLEBAR 'BKI'.
    WINDOW STARTING AT 30 5 ENDING AT 60 10.
    WRITE: 'Customer type :', sbook-custtype,
    / 'Smoker :', sbook-smoker,
    / 'Luggage weight :', sbook-luggweight UNIT 'KG',
    / 'Class :', sbook-class.
    ENDIF.
    ENDCASE.
    Regards,
    Raj.

  • Hide Statement support Deep Structure

    Hi
    would Hide Statement support Deep Structure?
    Regards
    Kumar
    Moderator message: please search for available information before asking, do not ask interview questions.
    locked by: Thomas Zloch on Sep 22, 2010 2:57 PM

    Hi,
    1) Yes..Hide supports deep structures..Example mentioned below..ALso the hidden values are not stored in the tables..I believe it will be stored in a memory..
    DATA: BEGIN OF wa,
           material TYPE mara,
          END OF wa.
    wa-material-matnr = 'MATERIAL1'.
    WRITE: wa-material-matnr.
    HIDE wa-material-matnr.
    CLEAR:wa-material-matnr.
    AT LINE-SELECTION.
      WRITE: / wa-material-matnr.
      CLEAR: wa-material-matnr.
    2) You cannot directly use INCLUDE statement like you do it in sap script..
    Instead you can call the FM READ_TEXT to get the text and print..
    Thanks,
    Naren

  • HIDE STATEMENT IS MUST OR NOT FOR INTERACTIVE REPORT

    HI,
      IN Interactive Report : without using the hide statement we will made the interactive report? and hide statement do its job after every increase of the sy-lsind please explain..
             thanks
               margani

    IT NOT BE MUST
    <u>HIDE</u>
    This statement stores - in the current list level - the content of the variable dobj together with the current list line whose line number is contained in sy-linno. The data type of the variables dobj must be flat and no field symbols can be specified that point to rows of internal tables, and no class attributes can be specified. The stored values can be read as follows:
    For each user action in a displayed screen list that leads to a list result, all the row values stored using HIDE - that is, the row on which the screen cursor is positioned at the time of the event - are assigned to the respective variables.
    If a list row of an arbitrary list level is read or modified using the statements READ LINE or MODIFY LINE, all the values of this row stored using HIDE are assigned to the respective variables.
    The HIDE statement works independently of whether the list cursor was set. In particular, variables for empty list rows can be stored - that is, rows in which the list cursor was positioned using statements like SKIP.
    The HIDE statement should be executed immediately at the statement that has set the list cursor in the row.
    Outside of classes, constants and literals that cannot be read in list results and in the statement READ LINE can be specified for dobj outside of classes.

  • How to use hide statement

    hi experts,
                  I am working with interactive report using hide statement.for thr first time it is working properly but the next time it is not working properly.Hope some clear statement has to be given ..
    Please give some simple progarm for interactiev report in list using hide statement.
    regards,
    mani

    HIDE dobj.
    Effect
    This statement stores the content of a variable dobj together with the current list line whose line number is contained in sy-linno in the hide area of the current list level. The data type of the variables dobj must be flat and no field symbols can be specified that point to rows of internal tables, and no class attributes can be specified. The stored values can be read as follows:
    For each user action in a displayed screen list that leads to a list result, all the row values stored using HIDE - that is, the row on which the screen cursor is positioned at the time of the event - are assigned to the respective variables.
    If a list row of an arbitrary list level is read or modified using the statements READ LINE or MODIFY LINE, all the values of this row stored using HIDE are assigned to the respective variables.
    Notes
    The HIDE statement works independently of whether the list cursor was set. In particular, variables for empty list rows can be stored - that is, rows in which the list cursor was positioned using statements like SKIP.
    The HIDE statement should be executed immediately at the statement that has set the list cursor in the row.
    Outside of classes, prior to release 7.0, for dobj constants and literals could still be specified. However, it was not possible to read them at list events and in the READ LINE statement.
    Example
    Storing square numbers and cubic numbers for a list of numbers. The example shows that arbitrary variables can be stored independently of row content. In the real situation, one would more likely store only the number and execute the calculation, when required, in the the event block for AT LINE-SELECTION.
    REPORT ...
    DATA: square TYPE i,
    cube TYPE i.
    START-OF-SELECTION.
    FORMAT HOTSPOT.
    DO 10 TIMES.
    square = sy-index ** 2.
    cube = sy-index ** 3.
    WRITE / sy-index.
    HIDE: square, cube.
    ENDDO.
    AT LINE-SELECTION.
    WRITE: square, cube.
    HIDE f.
    The contents of f related to the current output line are stored. If this line is selected, f is filled automatically with the stored value.
    The selection can be made using:
    AT LINE-SELECTION
    AT PFx
    AT USER-COMMAND
    READ LINE
    You do not have to output the field with WRITE in order to be able to store its value.
    The HIDE statement does not support structures that contain tables (deep structures).
    System fields that are particularly useful in interactive reporting are listed in the system fields for lists documentation.
    You cannot save lines or components of lines of an internal table that is addressed using a field symbol to the HIDE area. (Compare the ASSIGNING addition to the READ and LOOP statements). Assign the contents of the line or component to a global variable and save this instead.
    You can only write variables to the HIDEarea.
    In ABAP Objects, the following statements acause an error message:
    CONSTANTS f.
    HIDE: '...', f.
    Correct syntax:
    DATA: f1, f2.
    HIDE: f1, f2.
    Cause:
    Interactive list events cause the fields hidden by the HIDE command to be overwritten with values in the HIDE area, which means that they must be changeable.n.
    Reward points if useful.

  • Problem in HIDE statement

    Hi Guys,
    I have a query in <b>HIDE</b>, This is up gradation project 4.5B to ECC 6.0, but in the 4.5B it is working fine,When it come to the ECC 6.0 it is giving error like " you can not use <b>HIDE</b> for a read  only field.
    This is my statement:  "HIDE ICON_DISPLAY_MORE", please suggest me, is this statement correct?
    Thanks,
    Gourisankar.

    Try executing this program....
    you can understand...
    data: sym type ICON_D value '@1E@'.
    START-OF-SELECTION.
        FORMAT HOTSPOT.
        WRITE / 'ShowIcon'.
        HIDE: sym.
    AT LINE-SELECTION.
      WRITE: sym.
    And if i am not wrong, i hope you want to hide the "Display more" icon in the Select-options input. If that case, then use NO-EXTENSION keyword.
    Could you please tell me the exact requirement, why you want to hide that icon?

  • Error about hide statement

    Hi all,
    I am getting the error as You cannot use HIDE with a local field in my report.
    Please help me in solving this.
    Thanks.

    Hi,
    Declare the field as global or take a DDIC reference.
    Regards,
    Anirban

  • HIDE Command in ABAP

    What is the exact purpose of using a HIDE statement while making an interactive report? I know it is needed , but what purpose it exactly solves.

    F1 help.....
    HIDE
    Basic form
    HIDE f.
    In an ABAP Objects context, a more severe syntax check is performed that in other ABAP areas. See Constants not allowed in HIDE area.
    Effect
    Retains the contents of f related to the current output line. When the user selects the line from the list f is automatically filled with the retained value.
    The selection can occur in:
    AT LINE-SELECTION
    AT PFx
    AT USER-COMMAND
    READ LINE
    The contents of the field do not have to have been displayed using WRITE in order for you to retain them.
    The HIDE statement does not support deep structures (structures that contain internal tables).
    Useful system fields for interactive reporting are listed in the System Fields for Lists documentation.
    Note
    Lines or components of lines of an internal table that you address using a field symbol (see ASSIGNING addition to the READ and LOOP statements), cannot be retained using HIDE. You can store them using a global variable instead.
    Note
    Runtime errors:
    HIDE_FIELD_TOO_LARGE: The field is too long for HIDE.
    HIDE_ON_EMPTY_PAGE: HIDE not possible on an empty page.
    HIDE_NO_LOCAL: HIDE not possible for a local field.
    HIDE_ILLEGAL_ITAB_SYMBOL: HIDE not possible for a table line or component of a table line.
    and also a sample program.
    data: begin of itab occurs 0,
          field type c,
          end of itab.
    itab-field = 'A'.  append itab.
    itab-field = 'B'.  append itab.
    itab-field = 'C'.  append itab.
    itab-field = 'D'.  append itab.
    itab-field = 'E'.  append itab.
    loop at itab.
      format hotspot on.
      write:/ itab-field.
      hide itab-field.
      format hotspot off.
    endloop.
    at line-selection.
      write:/ 'You clicked', itab-field.
    null

  • Hide command

    What will exactly the hide statement do?

    Hi,
    HIDE statment is used to pass the value from one list to the other list.
    for exapmle if you are writing value of X inside a DO loop and after each write statment you are incrementing it by one.
    ex.
    DATA X TYPE I VALUE 1.
    Do 10 times.
    WRITE:/ X.
    X = X + 1.
    ENDDO.
    This statment will write values of X from 1 to 10 which will be printed on 1st list. Now suppose i ask you to design one more level of list that is interactive list in such a way that if user double click on a any number on the first list, same number should apper on the next list. In this case You will use AT LINE-SELECTION event but in AT LINE-SELECTION event if you will simply write WRITE X. it will print the last value of X which is 10 in this case(Because DO loop will be iterated for 10 times first and then it will come out seting value of X as 10) there fore to write the same value of X where user has double clicked SAP has given HIDE statment. It is specifically used in interactove list where HIDE statment makes it possible that the same value of variable will be available on the next list what was clicked on the the first list even if the variable's value has been changed.
    So in our case to write the same value we will write in this way.
    DATA X TYPE I VALUE 1.
    Do 10 times.
    WRITE:/ X.
    HIDE X.
    X = X + 1.
    ENDDO.
    AT LINE-SELECTION.
    WRITE X.
    You can hide more than one value so in your case HIDE matnr werks means these values will be same on the next level of list even if they have been changed.
    <b>Reward points if it is helpful.</b>
    Regards
    Tanweer

  • Concept of hide and clear

    Problem understanding hide and clear concept...
    for example, in the code below, it works fine with the write statement and have no problem with the output value when use the back button.
    however, when i use it to call a transaction (eg. mm03) and pass the value over, it seems to be a value behind (eg. when i click on row1, it gives a previously stored value. Press back button and when i click on row2, it gives me value of 1. Press back button and when i click on row5, it gives me value of 2. so the clear doesn't seem to "clear")
    what could be the problem? hope to understand this concept of hide and clear better (eg. when to clear?)...
    Cheers,
    Charles
    ABAP newbie
    DATA number(18) TYPE c.
    START-OF-SELECTION.
      CLEAR number.
      DO 9 TIMES.
        WRITE: / 'Row', (2) sy-index.
        number = sy-index.
        HIDE number.
      ENDDO.
    AT PF8.
      CHECK NOT number IS INITIAL.
      CALL TRANSACTION 'MM03'.
      SET PARAMETER ID 'MAT' FIELD number.
      CLEAR number.
    *  WRITE: / 'Cursor was in row', (2) NUMBER.

    hi,
    chk this.
    HIDE
    Basic form
    HIDE f.
    In an ABAP Objects context, a more severe syntax check is performed that in other ABAP areas.
    See Constants not allowed in HIDE area.
    Effect
    Retains the contents of f related to the current output line.
    When the user selects the line from the list f is automatically filled with the retained value.
    The selection can occur in:
    AT LINE-SELECTION
    AT PFx
    AT USER-COMMAND
    READ LINE
    The contents of the field do not have to have been displayed using WRITE in order for you to retain them.
    The HIDE statement does not support deep structures (structures that contain internal tables).
    Useful system fields for interactive reporting are listed in the System Fields for Lists documentation.
    Note
    Lines or components of lines of an internal table that you address using a field symbol (see ASSIGNING addition to the READ and LOOP statements), cannot be retained using HIDE. You can store them using a global variable instead.
    Note
    Runtime errors:
    HIDE_FIELD_TOO_LARGE: The field is too long for HIDE.
    HIDE_ON_EMPTY_PAGE: HIDE not possible on an empty page.
    HIDE_NO_LOCAL: HIDE not possible for a local field.
    HIDE_ILLEGAL_ITAB_SYMBOL: HIDE not possible for a table line or component of a table line.
    and also a sample program.
    report zxy_0003.
    data: begin of itab occurs 0,
    field type c,
    end of itab.
    itab-field = 'A'. append itab.
    itab-field = 'B'. append itab.
    itab-field = 'C'. append itab.
    itab-field = 'D'. append itab.
    itab-field = 'E'. append itab.
    loop at itab.
    format hotspot on.
    write:/ itab-field.
    hide itab-field.
    format hotspot off.
    endloop.
    at line-selection.
    write:/ 'You clicked', itab-field.
    It kind of "remembers" what is written, so that when you click on it, it knows what the value is.
    Regards,
    anver

Maybe you are looking for

  • How do I create a back up disk?

    I bought a Lacie External Harddrive along with my MacBook last summer and I have yet to back up any of my work. I bought because my last hard drive crashed so upon getting a new computer I wanted to avoid losing all my data again. I was told in ordde

  • RMI + LAN = trouble !!

    my server is a linux machine with ip 192.168.100.76. i have made an email service in which my smtp and pop3 are installed in the linux server i have made a client application which fetches the mail from the server.. Now the problem we know that the s

  • Quantity delivered differs from qty invoiced

    Experts, SRM 5/Ext classic For one of the line items in SRM PO, we wanted to set the deletion indicator which we have done by maintaining table entry DEL_INDICATOR....but this deletion indicator is not visible against line item in ECC PO when we tran

  • Ore.doEval funciton returning the error

    Hi, I have just started leaning Oracle R enterprise. I have installed Database 11.2.0.3 and R in Oracle Linux guest machine. and connecting from windows8 host machine. I am able successfully configure the client and server and able to connect to data

  • On Mac, why won't the downloaded PDF form SUBMIT after being filled out?

    On Mac, why won't the downloaded PDF form SUBMIT after being filled out? Thank you for the help. Kind regards Ryan Kohler