Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

about readline.

Former Member
0 Likes
921

hi,

pls tell me what is meaning of cammand 'read line <linno >fieldvalue <field>'

pls tell me with example.

if i am using in the write statement.

write : a as checkbox

in the secondary list it should show like how many checkbox has been clicked.

for this i written like this.

set pf status 'check'.

at user-command.

when 'select'.

read line sy-linno field value a.

when a = 'X'.

.

if there there are number check boxes how to count all.

if i am using check

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
875

The addition<b> EXCLUDING</b> can be used to deactivate functions of the set GUI status. An inactive function cannot be selected in the user interface. For fcode, either a character-type data object or an internal table with a flat character-type data type can be specified. The functions, whose function codes are contained in the field or in the rows of the internal table, are deactivated. Only one function code can be specified for each row of the table. The codes are not case-sensitive. Function codes specified in fcode, for which there is no function in the GUI status, are ignored.

reward points if it is usefull ....

Girish

The addition<b> EXCLUDING</b> can be used to deactivate functions of the set GUI status. An inactive function cannot be selected in the user interface. For fcode, either a character-type data object or an internal table with a flat character-type data type can be specified. The functions, whose function codes are contained in the field or in the rows of the internal table, are deactivated. Only one function code can be specified for each row of the table. The codes are not case-sensitive. Function codes specified in fcode, for which there is no function in the GUI status, are ignored.

reward points if it is usefull ....

Girish

6 REPLIES 6
Read only

Former Member
0 Likes
875

Hi,

Store the tabix of the record where check box is ticked into an internal table.

for eg.

Type : begin of ttab,

index type sy-tabix,

end of ttab.

data : itab type standard table of ttab,

wa_tab type ttab.

set pf status 'check'.

at user-command.

when 'select'.

read line sy-linno field value a.

when a = 'X'.

clear wa_tab.

wa_tab-index = sy-linno.

append wa_tab to itab.

Do it for all the checkboxes. finally itab will have all the records where checkbox is ticked.

Best regards,

Prashant

Read only

Former Member
0 Likes
875

Here is the program of the <b>drilldown report using the check box and the read line statement also ......</b>


REPORT zdemo_list_modify_field_format NO STANDARD PAGE HEADING.

DATA: box(1) TYPE c, lines TYPE i, num(1) TYPE c.

SET PF-STATUS 'CHECK'.

DO 5 TIMES.
  num = sy-index.
  WRITE: / box AS CHECKBOX, 'Line', num.
  HIDE: box, num.
ENDDO.
lines = sy-linno.

TOP-OF-PAGE.
  WRITE  'Select some checkboxes'.
  ULINE.

AT USER-COMMAND.
  CASE sy-ucomm.
    WHEN 'READ'.
      SET PF-STATUS 'CHECK' EXCLUDING 'READ'.
      box = space.
      DO lines TIMES.
        READ LINE sy-index FIELD VALUE box.
        IF box = 'X'.
          WRITE: / 'Line', num, 'was selected'.
          box = space.
          MODIFY LINE sy-index
                      FIELD VALUE  box
                      FIELD FORMAT box INPUT OFF
                                   num COLOR 6 INVERSE ON.
        ENDIF.
      ENDDO.
  ENDCASE. 

<b>Note :</b>

Just double click on the <b>PF-STATUS 'CHECK'.</b> so that <b>se51 There</b> in the Function key give <b> READ</b> to any one of the icon .. <b>save & activate </b> ... so that the ICon will appear in the program executed in the basic list .... select the check box of your list doble click on the I<b>CON</b> see the selected data will be listed in the secondary list .....

reward points if it is usefull ...

Girish

Read only

0 Likes
875

what is this SET PF-STATUS 'CHECK' EXCLUDING 'READ'. means

Read only

0 Likes
875

Hi,

It means the PF-STATUS 'check' is set but without button or menu item or anything of PF-STATUS associated with function code 'READ'.

Reward points if useful.

Thanks,

Dipesh Jhala

Read only

Former Member
0 Likes
875

Hi,

The system internally stores all lists created in succession by one report program. Therefore, you can access any list from within the program that was created during the current dialog session and has not been deleted by returning to a previous list level.

READ LINE <n> [INDEX <index>]

[FIELD VALUE <f1> [INTO <g1>] ... <fn> [INTO <gn>]]

[OF CURRENT PAGE|OF PAGE <n>].

READ CURRENT LINE

[FIELD VALUE <f1> [INTO <g1>] ... <fn> [INTO <gn>]]

Stores the contents of line from the list on which the event was triggered (list index SY-LISTI, line number SY-LILLI) in the SY-LISEL system field and fills all HIDE information stored for this line back into the corresponding fields.

SY-SUBRC = 0 : Ok; = 4 : line does not exist.

Fields that do not appear in a line, do not affect the target field. If a field appears several times in a line, the system uses only the first one.

For More Info refer http://help.sap.com/saphelp_nw04/helpdata/en/9f/dba42335c111d1829f0000e829fbfe/content.htm

Regards

Bhavani BL

Read only

Former Member
0 Likes
876

The addition<b> EXCLUDING</b> can be used to deactivate functions of the set GUI status. An inactive function cannot be selected in the user interface. For fcode, either a character-type data object or an internal table with a flat character-type data type can be specified. The functions, whose function codes are contained in the field or in the rows of the internal table, are deactivated. Only one function code can be specified for each row of the table. The codes are not case-sensitive. Function codes specified in fcode, for which there is no function in the GUI status, are ignored.

reward points if it is usefull ....

Girish