‎2007 Jun 21 7:44 AM
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.
‎2007 Jun 21 8:01 AM
Singh,
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.
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.
The example below presents some of the essential features of interactive reporting. The basic list contains summarized information. By means of the HIDE technique, each detail list contains more details.
Don't forget to reward if useful....
‎2007 Jun 21 7:59 AM
hi,
hide command stores that particular field in ssystem buffer.e.g.,u have a basic list and u want to display detailed list.after clicking a certain record in basic list,there should be some key to go to detail list.it is provided by HIDE command.Based on that field detailed list is displayed.
‎2007 Jun 21 8:02 AM
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
‎2007 Jun 21 8:06 AM
Hi Vishal,
I made a report which displays 100 entries , and HIDE works only when I put it inside the loop that displays those entries. I tried using it in at line selection , just before at line selection and lots of other places as well.
Why is it so that everytime a record is displayed , we have to hide it. If the system stores it in a system buffer , then as per your answer , system buffers all the records displayed. Is that the case?
‎2007 Jun 21 8:01 AM
Singh,
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.
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.
The example below presents some of the essential features of interactive reporting. The basic list contains summarized information. By means of the HIDE technique, each detail list contains more details.
Don't forget to reward if useful....
‎2007 Jun 21 8:27 AM
Hi
You have to follow some sequence for this HIDE command
You can't write here and there as you wish.
the sequence is
SELECT
WRITE
HIDE
CLEAR ENDSELECT
or
with in the LOOP...WRITE..HIDE.ENDLOOP.
Reward points for useful Answers
Regards
Anji
Message was edited by:
Anji Reddy Vangala
‎2007 Jun 21 8:36 AM