‎2007 May 30 5:34 AM
Hi guys,
i want to call subscreen in another screen, in that subscreen i want to call another screen and one table control screen... plz can any one send me the logic... of this Development....
‎2007 May 30 5:57 AM
Hi,
I think its not possible to call a screen in a sub-screen. In a sub-screen you can call another sub-screen only..
Regards,
sudha
‎2007 May 30 6:19 AM
hi,
u can't call a normal screen from subscreen but u can call anothe rsubscreen and place table control in it.
ex: in this i am using normal screen 100 and in that i am calling subscreen which contain table control.
In screen 100 i took vendor number,name and land1from copy repository.i took three buttons display,sales exit.ehen i click display it will display vendor information.when i click sales it will call 200 subscreen.and to 300 for tem details
flow logic of 100:
process before output.
module status_0100.
process after input.
module user_command_0100.
flow logic for 200.(table control logic)
process before output.
loop at itab1 with control tc2.
module status_0200.
endloop.
process after input.
module user_command_0200.
loop at itab1.
endloop.
this the program.
report zhm_multtc .
tables : kna1, vbak, vbap.
data: begin of itab occurs 0,
kunnr like kna1-kunnr,
land1 like kna1-land1,
name1 like kna1-name1,
end of itab.
data: begin of itab1 occurs 0,
kunnr like vbak-kunnr,
vbeln like vbak-vbeln,
erdat like vbak-erdat,
netwr like vbak-netwr,
end of itab1.
data: begin of itab2 occurs 0,
vbeln like vbap-vbeln,
posnr like vbap-posnr,
matnr like vbap-matnr,
end of itab2.
data: fnam(10), fval(10) type n.
controls tc2 type tableview using screen '200'.
&----
*& Module USER_COMMAND_0100 INPUT
&----
module user_command_0100 input.
case sy-ucomm.
when 'DISPLAY'.
refresh itab.
select kunnr land1 name1 from kna1 into itab where kunnr = kna1-kunnr.
append itab.
endselect.
<b> when 'SALES'.
refresh itab1.
select kunnr vbeln erdat netwr from vbak into itab1 where kunnr = kna1-kunnr.
append itab1.
endselect.
call screen 200.
</b> when 'EXIT'.
leave program.
endcase.
endmodule. " USER_COMMAND_0100 INPUT
&----
*& Module STATUS_0100 OUTPUT
&----
text
----
module status_0100 output.
SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR 'xxx'.
move-corresponding itab to kna1.
endmodule. " STATUS_0100 OUTPUT
&----
*& Module USER_COMMAND_0200 INPUT
&----
text
----
module user_command_0200 input.
case sy-ucomm.
when 'BACK'.
leave to screen '100'.
when 'ITEM'.
refresh itab2.
get cursor field fnam value fval.
select vbeln posnr matnr from vbap into itab2 where vbeln = vbak-vbeln.
append itab2.
endselect.
call screen '200'.
when 'EXIT'.
leave program.
endcase.
endmodule. " USER_COMMAND_0200 INPUT
&----
*& Module STATUS_0200 OUTPUT
&----
text
----
module status_0200 output.
SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR 'xxx'.
move-corresponding itab1 to vbak.
endmodule. " STATUS_0200 OUTPUT
&----
*& Module USER_COMMAND_0300 INPUT
&----
text
----
module user_command_0300 input.
case sy-ucomm.
when 'BACK'.
leave to screen '200'.
when 'EXIT'.
leave program.
endcase.
endmodule. " USER_COMMAND_0300 INPUT
&----
*& Module STATUS_0300 OUTPUT
&----
module status_0300 output.
SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR 'xxx'.
move-corresponding itab2 to vbap.
vbak-vbeln = fval.
endmodule. " STATUS_0300 OUTPUT