2009 Aug 06 8:37 AM
Hi All,
i am using a custom table and the maintatance of the table is accessed by multi user and it allows the data locked by one user to another . My requirment is to make the desired seletion screen instead of the whole selection screen from the table .
I am getttign the initial selection screen for my table has many fiellds but user interted only to display 4 fields . i am using the FM VIEW_MAINTENANCE_CALL.
How can i make the selection scrren with only few fields . plz advise me .
Please fidn the below code for your refernece.
CONSTANTS: c_rstable(7) TYPE c VALUE 'RSTABLE',
c_zdcopipo TYPE dd02v-tabname VALUE 'ZDCOPIPO',
c_c(12) TYPE c VALUE '*',
c_1 TYPE sy-subrc VALUE '1',
c_u(1) TYPE c VALUE 'U',
c_x(1) TYPE c VALUE 'X',
c_gname TYPE seqg3-gname VALUE space,
c_garg TYPE seqg3-garg VALUE space,
c_popup TYPE xfeld VALUE space,
c_supress TYPE xfeld VALUE space.
*Selection range for view maintenance
TYPES: BEGIN OF y_selekttab .
INCLUDE STRUCTURE vimsellist.
TYPES: END OF y_selekttab.
*Table of inactive CUA functions for view maintenance
TYPES: BEGIN OF y_excl_cua_funct.
INCLUDE STRUCTURE vimexclfun.
TYPES: END OF y_excl_cua_funct.
TYPES: BEGIN OF y_seqg3.
INCLUDE STRUCTURE seqg3.
TYPES: END OF y_seqg3.
TYPES: BEGIN OF y_seqg7.
INCLUDE STRUCTURE seqg7.
TYPES: END OF y_seqg7.
DATA: t_selekttab TYPE STANDARD TABLE OF y_selekttab,
t_excl_cua_funct TYPE STANDARD TABLE OF y_excl_cua_funct,
t_enq_del TYPE STANDARD TABLE OF y_seqg3 ,
t_enq_read TYPE STANDARD TABLE OF y_seqg7.
DATA: e_enq_read TYPE y_seqg7,
e_enq_del TYPE y_seqg3,
w_subrc TYPE sy-subrc.
FIELD-SYMBOLS: <fs_enq_read> TYPE seqg7.
INITIALIZATION.
FREE: t_selekttab,
t_excl_cua_funct,
t_enq_del,
t_enq_read.
CLEAR:e_enq_read,
e_enq_del,
w_subrc.
START-OF-SELECTION.
*Read all the lock details in system
CALL FUNCTION 'ENQUE_READ2'
EXPORTING
gclient = sy-mandt
gname = c_gname
garg = c_garg
guname = c_c
* IMPORTING
* NUMBER =
* SUBRC =
TABLES
enq = t_enq_read.
IF sy-subrc EQ 0.
* search entry for table level lock for our table
UNASSIGN: <fs_enq_read>.
LOOP AT t_enq_read
ASSIGNING <fs_enq_read>
WHERE gname EQ c_rstable
AND garg CS c_zdcopipo.
MOVE: <fs_enq_read>-gname TO e_enq_del-gname,
<fs_enq_read>-garg TO e_enq_del-garg,
<fs_enq_read>-gmode TO e_enq_del-gmode,
<fs_enq_read>-gusr TO e_enq_del-gusr,
<fs_enq_read>-gusrvb TO e_enq_del-gusrvb,
<fs_enq_read>-guse TO e_enq_del-guse,
<fs_enq_read>-gusevb TO e_enq_del-gusevb,
<fs_enq_read>-gobj TO e_enq_del-gobj,
<fs_enq_read>-gclient TO e_enq_del-gclient,
<fs_enq_read>-guname TO e_enq_del-guname,
<fs_enq_read>-gtcode TO e_enq_del-gtcode,
<fs_enq_read>-gbcktype TO e_enq_del-gbcktype.
APPEND e_enq_del TO t_enq_del.
CLEAR e_enq_del.
ENDLOOP.
ENDIF." enq_read
* Delete table level lock entry for our table
CALL FUNCTION 'ENQUE_DELETE'
EXPORTING
check_upd_requests = c_1
* SUPPRESS_SYSLOG_ENTRY = ' '
IMPORTING
subrc = w_subrc
TABLES
enq = t_enq_del.
IF sy-subrc EQ 0.
* null check
ENDIF.
*if sy-subrc eq 0.
* call the table maintenace generator.
CALL FUNCTION 'VIEW_MAINTENANCE_CALL'
EXPORTING
action = c_u
* CORR_NUMBER = ' '
* GENERATE_MAINT_TOOL_IF_MISSING = ' '
show_selection_popup = c_popup "'X' "
view_name = c_zdcopipo
* NO_WARNING_FOR_CLIENTINDEP = ' '
* RFC_DESTINATION_FOR_UPGRADE = ' '
* CLIENT_FOR_UPGRADE = ' '
* VARIANT_FOR_SELECTION = ' '
* COMPLEX_SELCONDS_USED = ' '
* CHECK_DDIC_MAINFLAG = ' '
suppress_wa_popup = c_supress "'X' "
TABLES
dba_sellist = t_selekttab
excl_cua_funct = t_excl_cua_funct
* EXCEPTIONS
* CLIENT_REFERENCE = 1
* FOREIGN_LOCK = 2
* INVALID_ACTION = 3
* NO_CLIENTINDEPENDENT_AUTH = 4
* NO_DATABASE_FUNCTION = 5
* NO_EDITOR_FUNCTION = 6
* NO_SHOW_AUTH = 7
* NO_TVDIR_ENTRY = 8
* NO_UPD_AUTH = 9
* ONLY_SHOW_ALLOWED = 10
* SYSTEM_FAILURE = 11
* UNKNOWN_FIELD_IN_DBA_SELLIST = 12
* VIEW_NOT_FOUND = 13
* MAINTENANCE_PROHIBITED = 14
* OTHERS = 15
.
IF sy-subrc NE 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
Please advise how can i modify the input screen.
Hi All,
i am using a custom table and the maintatance of the table is accessed by multi user and it allows the data locked by one user to another . My requirment is to make the desired seletion screen instead of the whole selection screen from the table .
I am getttign the initial selection screen for my table has many fiellds but user interted only to display 4 fields . i am using the FM VIEW_MAINTENANCE_CALL.
How can i make the selection scrren with only few fields . plz advise me .
Please fidn the below code for your refernece.
CONSTANTS: c_rstable(7) TYPE c VALUE 'RSTABLE',
c_zdcopipo TYPE dd02v-tabname VALUE 'ZDCOPIPO',
c_c(12) TYPE c VALUE '*',
c_1 TYPE sy-subrc VALUE '1',
c_u(1) TYPE c VALUE 'U',
c_x(1) TYPE c VALUE 'X',
c_gname TYPE seqg3-gname VALUE space,
c_garg TYPE seqg3-garg VALUE space,
c_popup TYPE xfeld VALUE space,
c_supress TYPE xfeld VALUE space.
*Selection range for view maintenance
TYPES: BEGIN OF y_selekttab .
INCLUDE STRUCTURE vimsellist.
TYPES: END OF y_selekttab.
*Table of inactive CUA functions for view maintenance
TYPES: BEGIN OF y_excl_cua_funct.
INCLUDE STRUCTURE vimexclfun.
TYPES: END OF y_excl_cua_funct.
TYPES: BEGIN OF y_seqg3.
INCLUDE STRUCTURE seqg3.
TYPES: END OF y_seqg3.
TYPES: BEGIN OF y_seqg7.
INCLUDE STRUCTURE seqg7.
TYPES: END OF y_seqg7.
DATA: t_selekttab TYPE STANDARD TABLE OF y_selekttab,
t_excl_cua_funct TYPE STANDARD TABLE OF y_excl_cua_funct,
t_enq_del TYPE STANDARD TABLE OF y_seqg3 ,
t_enq_read TYPE STANDARD TABLE OF y_seqg7.
DATA: e_enq_read TYPE y_seqg7,
e_enq_del TYPE y_seqg3,
w_subrc TYPE sy-subrc.
FIELD-SYMBOLS: <fs_enq_read> TYPE seqg7.
INITIALIZATION.
FREE: t_selekttab,
t_excl_cua_funct,
t_enq_del,
t_enq_read.
CLEAR:e_enq_read,
e_enq_del,
w_subrc.
START-OF-SELECTION.
*Read all the lock details in system
CALL FUNCTION 'ENQUE_READ2'
EXPORTING
gclient = sy-mandt
gname = c_gname
garg = c_garg
guname = c_c
* IMPORTING
* NUMBER =
* SUBRC =
TABLES
enq = t_enq_read.
IF sy-subrc EQ 0.
* search entry for table level lock for our table
UNASSIGN: <fs_enq_read>.
LOOP AT t_enq_read
ASSIGNING <fs_enq_read>
WHERE gname EQ c_rstable
AND garg CS c_zdcopipo.
MOVE: <fs_enq_read>-gname TO e_enq_del-gname,
<fs_enq_read>-garg TO e_enq_del-garg,
<fs_enq_read>-gmode TO e_enq_del-gmode,
<fs_enq_read>-gusr TO e_enq_del-gusr,
<fs_enq_read>-gusrvb TO e_enq_del-gusrvb,
<fs_enq_read>-guse TO e_enq_del-guse,
<fs_enq_read>-gusevb TO e_enq_del-gusevb,
<fs_enq_read>-gobj TO e_enq_del-gobj,
<fs_enq_read>-gclient TO e_enq_del-gclient,
<fs_enq_read>-guname TO e_enq_del-guname,
<fs_enq_read>-gtcode TO e_enq_del-gtcode,
<fs_enq_read>-gbcktype TO e_enq_del-gbcktype.
APPEND e_enq_del TO t_enq_del.
CLEAR e_enq_del.
ENDLOOP.
ENDIF." enq_read
* Delete table level lock entry for our table
CALL FUNCTION 'ENQUE_DELETE'
EXPORTING
check_upd_requests = c_1
* SUPPRESS_SYSLOG_ENTRY = ' '
IMPORTING
subrc = w_subrc
TABLES
enq = t_enq_del.
IF sy-subrc EQ 0.
* null check
ENDIF.
*if sy-subrc eq 0.
* call the table maintenace generator.
CALL FUNCTION 'VIEW_MAINTENANCE_CALL'
EXPORTING
action = c_u
* CORR_NUMBER = ' '
* GENERATE_MAINT_TOOL_IF_MISSING = ' '
show_selection_popup = c_popup "'X' "
view_name = c_zdcopipo
* NO_WARNING_FOR_CLIENTINDEP = ' '
* RFC_DESTINATION_FOR_UPGRADE = ' '
* CLIENT_FOR_UPGRADE = ' '
* VARIANT_FOR_SELECTION = ' '
* COMPLEX_SELCONDS_USED = ' '
* CHECK_DDIC_MAINFLAG = ' '
suppress_wa_popup = c_supress "'X' "
TABLES
dba_sellist = t_selekttab
excl_cua_funct = t_excl_cua_funct
* EXCEPTIONS
* CLIENT_REFERENCE = 1
* FOREIGN_LOCK = 2
* INVALID_ACTION = 3
* NO_CLIENTINDEPENDENT_AUTH = 4
* NO_DATABASE_FUNCTION = 5
* NO_EDITOR_FUNCTION = 6
* NO_SHOW_AUTH = 7
* NO_TVDIR_ENTRY = 8
* NO_UPD_AUTH = 9
* ONLY_SHOW_ALLOWED = 10
* SYSTEM_FAILURE = 11
* UNKNOWN_FIELD_IN_DBA_SELLIST = 12
* VIEW_NOT_FOUND = 13
* MAINTENANCE_PROHIBITED = 14
* OTHERS = 15
.
IF sy-subrc NE 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
Please advise how can i modify the input screen.
2009 Aug 06 12:01 PM
hi,
Goto the Element list of Corresponding screen(Screen property) and modify the Display Invisible option.
Thanks ,
AJR
2009 Aug 06 12:11 PM
Hi A J Raj ,
Thanks for your reply
IF i edit the maintanance screen attributes that will only effect the maintanance screen . but i want to edit the selection screen in the begining of the program . for ex . when the user executes the program the secltion screen should display only the sales org , dist channel and material . but now i m able to display all the fields of the table .
all fields are apperaing the selection since the input to the FM VIEW_MAINTENANCE_CALL is the table . i want to aviod this .
Please help..
Regards
basavaraj
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |