Calling a Transaction from Selection screen of Z Program...
Hi,
I am trying to call a Standard transaction from a report when they clicked one push button on selection screen.
when i used CALL TRANSACTION 'MM01'. When i press save after entering the values in MM01, it is saving and coming out to selection screen of my Z program.
But my question is when they press in BACK button in MM01 then only it should come out from MM01 and it should display the my Z Program selection screen. suppose if they press SAVE button on MM01 it should save and screen should be MM01 only.
when i used LEAVE TO TRANSACTION 'MM01'. it is working fine but when i press BACK button from MM01 it is coming out and showing SAP EASY ACCESS screen. My requirement is when i press back button in MM01 then it must come to my Z program selection screen only.
I hope it is clear.
Regards,
Sunny
>
sunny_143 wrote:
> Hi,
>
> I am trying to call a Standard transaction from a report when they clicked one push button on selection screen.
>
> when i used CALL TRANSACTION 'MM01'. When i press save after entering the values in MM01, it is saving and coming out to selection screen of my Z program.
>
> But my question is when they press in BACK button in MM01 then only it should come out from MM01 and it should display the my Z Program selection screen. suppose if they press SAVE button on MM01 it should save and screen should be MM01 only.
>
>
> when i used LEAVE TO TRANSACTION 'MM01'. it is working fine but when i press BACK button from MM01 it is coming out and showing SAP EASY ACCESS screen. My requirement is when i press back button in MM01 then it must come to my Z program selection screen only.
>
> I hope it is clear.
>
> Regards,
> Sunny
I'm not clear about what happens when you press the BACK button.
First, LEAVE TO TRANSACTION is no help. That ends your Z program. CALL TRANSACTION is your only option. If it doesn't work as you'd like, you're a bit stuck, as MMnn are standard SAP transactions, and you can't modify that. (well, you can, but that's a whole other tin of worms).
Perhaps if you told us what you're trying to achieve with the Z program, there might be another approach that will do that.
matt
Similar Messages
-
Restrict 'Executing report in background' from selection screen
I want user to not to select option for executing report in background from Selection Screen of the program.
i.e. 'Execute Program in Background' option in 1st menu bar tab should either be disabled OR if user clicks on it then he should get error message on selection screen itself.
Thanks,
FalguniHi Falguni,
Write the code based on function code SJOB in the event AT SELECTION-SCREEN. Write the following code :
AT SELECTION-SCREEN
CASE SY-UCOMM.
WHEN 'SJOB'.
MESSAGE E000 WITH 'You cannot schedule background job'.
ENDCASE.
Thanks & Regards,
Faheem. -
HOW TO PASS THE DATA FROM SELECTION SCREEN TO STANDARD TRANSACTION?
HI,
HOW TO PASS THE DATA FROM SELECTION SCREEN TO STANDARD TRANSACTION?
thanks,
samba.By selection screen, what do you mean? There is no selection screen in WDA as there was in classic dynpro. Do you mean you are using the Select-Options reusable component? Are you wanting to call a standard transaction via ITS - SAPGUI for HTML? Please provide more details to your question.
-
RESCIS - Unable to select custom report from Selection Screen
Hi all,
we have developed a custom report for transaction "RESCIS-Evaluation of service charge settlement" but we have found that althought the report appears in selection screen field called "REPORT" it throws message RESCIS003 but the report is not shown.
If we doesn't fulfill report field in selection screen, the program shows a second screen where a couple of ALVGrids are shown allowing the user to select the report that will be displayed. Here we are able to select our custom report and the data in it is displayed.
We have analyzed the standard program that is executed via transaction RESCIS and we've found that the selection screen executes standard function RESC_GUI_ANYREPORTS_APPL that doesn't executes reports dinamically but statically. That means that SAP doesn't allows to execute custom reports directly from selection screen.
I think this is a SAP error but afert opening an OSS message SAP sais that is not an error but a bad configuration or lack of knowledge for customizing it.
Has anyone developed a custom report for RESCIS transaction?Hm what exactly did you want to change? Normally it is in REFX cases you should not copy standard REPORTS. In your case with transaction RESCIS, I myself do not see any need to add any functionality in this report because it is only a sum of all lists from your service charge settlement. What else do you want to see there?
For displaying new fields in the separate lists maybe there is some BADI for it.
Regards
Michael -
Calling selection screen of another program
Hi all,
Am trying to call a program from a enhancement section of IW3K transaction using the following statement.But the selection screen of the program is not getting displayed.
but the screen is dispalyed when i run the statement in debug mode.
Can anyone help me on this...
useful answers will be rewarded.
submit Z XXXXX via selection-screen
WITH s_ispla = 'BEKD'
WITH p_rsnum = CAUFVD-rsnum
WITH s_rspos in i_range_tab
and RETURN.hi,
You can call one selection screen from other selection screen program using SUBMIT command.
The syntax is as follows -
codeSUBMIT... VIA SELECTION-SCREEN
USING SELECTION-SET <var>
WITH <sel> <criterion>
WITH FREE SELECTIONS <freesel>
WITH SELECTION-TABLE <rspar>.[/code]
e.g.
The following executable program (report) creates a selection screen containing the parameter PARAMET and the selection criterion SELECTO:
codeREPORT demo_program_submit_rep1.
DATA number TYPE i.
PARAMETERS paramet(14) TYPE c.
SELECT-OPTIONS selecto FOR number.[/code]
The program DEMO_PROGRAM_SUBMIT_REP1 is called by the following program using various parameters:
codeREPORT demo_program_submit_sel_screen NO STANDARD PAGE HEADING.
DATA: int TYPE i,
rspar TYPE TABLE OF rsparams,
wa_rspar LIKE LINE OF rspar.
RANGES seltab FOR int.
WRITE: 'Select a Selection!',
SKIP.
FORMAT HOTSPOT COLOR 5 INVERSE ON.
WRITE: 'Selection 1',
/ 'Selection 2'.
AT LINE-SELECTION.
CASE sy-lilli.
WHEN 4.
seltab-sign = 'I'. seltab-option = 'BT'.
seltab-low = 1. seltab-high = 5.
APPEND seltab.
SUBMIT demo_program_submit_rep1 VIA SELECTION-SCREEN
WITH paramet eq 'Selection 1'
WITH selecto IN seltab
WITH selecto ne 3
AND RETURN.
WHEN 5.
wa_rspar-selname = 'SELECTO'. wa_rspar-kind = 'S'.
wa_rspar-sign = 'E'. wa_rspar-option = 'BT'.
wa_rspar-low = 14. wa_rspar-high = 17.
APPEND wa_rspar TO rspar.
wa_rspar-selname = 'PARAMET'. wa_rspar-kind = 'P'.
wa_rspar-low = 'Selection 2'.
APPEND wa_rspar TO rspar.
wa_rspar-selname = 'SELECTO'. wa_rspar-kind = 'S'.
wa_rspar-sign = 'I'. wa_rspar-option = 'GT'.
wa_rspar-low = 10.
APPEND wa_rspar TO rspar.
SUBMIT demo_program_submit_rep1 VIA SELECTION-SCREEN
WITH SELECTION-TABLE rspar
AND RETURN.
ENDCASE.[/code]
=> To leave a called program, you can use SUBMIT .... AND RETURN. by choosing F3 or F15 from list level 0 of the called report. -
Can we call a transaction from a report
hi
can we call a transaction from a reporthi,
we can call
check it
*& Report ZSALESORDERDETAILS_ASHOK
REPORT ZSALESORDERDETAILS_ASHOK
NO STANDARD PAGE HEADING
LINE-SIZE 50
LINE-COUNT 35(5).
*data declaration.
tables :vbak.
tables: VBAP.
DATA : TVBAK LIKE VBAK OCCURS 0 WITH HEADER LINE,
TVBAP LIKE VBAP OCCURS 0 WITH HEADER LINE,
TEMP TYPE p decimals 5 VALUE '0.0' ,
A type i,
FIELDNAME TYPE STRING,
FIELDVALUE TYPE VBAP-VBELN.
DATA G_CB.
selection-screen begin of block screen1 with frame title TEXT-001.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN COMMENT /32(35) COMM1.
SELECTION-SCREEN ULINE /27(35).
SELECTION-SCREEN SKIP.
SELECT-OPTIONS TVBELN FOR VBAK-VBELN.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN ULINE.
SELECTION-SCREEN COMMENT /30(50) COMM2.
SELECTION-SCREEN ULINE /27(40).
SELECTION-SCREEN SKIP.
SELECT-OPTIONS TERDAT FOR VBAK-ERDAT.
SELECTION-SCREEN SKIP.
selection-screen end of block screen1.
*Initialization
Initialization .
TVBELN-low = 4000.
TVBELN-high = 5000.
TVBELN-option = 'BT'.
TVBELN-sign = 'I'.
APPEND TVBELN.
TERDAT-low = '19960202'.
TERDAT-high = '20020302' .
APPEND TERDAT.
AT SELECTION-SCREEN .
SELECT *
FROM VBAK
INTO TABLE TVBAK
WHERE VBELN IN TVBELN AND erdat IN Terdat .
IF sy-subrc ne 0.
MESSAGE 'ENTERED ORDER NOT FOUND' type 'E'.
ENDIF.
START-OF-SELECTION.
REFRESH TVBAK.
SELECT *
FROM VBAK
INTO TABLE TVBAK
WHERE VBELN IN TVBELN AND ERDAT IN TERDAT.
END-OF-SELECTION.
LOOP AT TVBAK.
WRITE: /2 SY-VLINE,
TVBAK-VBELN INPUT ON ,
15 SY-VLINE,TVBAK-ERDAT hotspot on,
30 SY-VLINE, 35 TVBAK-ERNAM,
46 SY-VLINE,
g_cb AS CHECKBOX.
ENDLOOP.
A = SY-LINCT - SY-LINNO - 1.
SKIP A .
RESERVE A LINES.
AT SELECTION-SCREEN OUTPUT.
comm1 ='SELECT SALES ORDER RANGE'.
comm2 ='SELECT SALES ORDER CREATION DATE'.
TOP-OF-PAGE.
ULINE.
WRITE /15 ' SALES ORDER REPORT ' COLOR = 1 .
ULINE.
WRITE : /7 ' VBELN ' COLOR = 5 ,
19 ' ERDAT ' COLOR = 5,
34 ' ERNAM ' COLOR = 5.
ULINE.
END-OF-PAGE.
IF SY-LSIND = 0.
ULINE.
WRITE : /2 'NUMBER OF LINE IN THIS PAGE = ', SY-LINNO.
SKIP.
WRITE: /30 'PAGE NUMBER = ', SY-PAGNO.
ULINE.
ELSEIF SY-LSIND = 1.
ULINE.
WRITE : /12 'TOTAL PRICE = ' ,TEMP.
CLEAR TEMP.
SKIP.
WRITE : /30 'PAGE NUMBER = ', SY-PAGNO.
ULINE.
ENDIF.
at line-selection.
GET CURSOR FIELD FIELDNAME VALUE FIELDVALUE.
IF FIELDNAME = 'TVBAK-VBELN'.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
INPUT = FIELDVALUE
IMPORTING
OUTPUT = FIELDVALUE.
WINDOW STARTING AT 60 2 ENDING AT 120 25.
IF SY-LSIND = 1.
SELECT
FROM VBAP
INTO TABLE TVBAP
WHERE VBELN EQ FIELDVALUE.
LOOP AT TVBAP.
TEMP = TEMP + TVBAP-NETPR.
WRITE : /2 SY-VLINE, TVBAP-matnr,
17 SY-VLINE,TVBAP-VBELN,
30 SY-VLINE,TVBAP-NETPR currency 'IN',
49 SY-VLINE.
ENDLOOP.
ULINE.
A = SY-LINCT - SY-LINNO - 1.
SKIP A .
RESERVE A LINES.
ENDIF.
<b>ELSEIF SY-LSIND = 2.
call transaction 'MM01' .
ENDIF.</b>
TOP-OF-PAGE DURING LINE-SELECTION.
WRITE : / SY-ULINE,
/7 ' DETAIL OF GIVEN SALES ORDER ' COLOR = 5,
/ SY-ULINE,
/4 'MATNR',
22 'VBELN',
35 'NETPR',
/ SY-ULINE.
Regards
ASHOK
Message was edited by:
ASHOK KUMAR -
Possible to call a transaction from a planning book using a macro button?
Hi All,
Is it somehow possible to call a transaction using a macro button in the planning book? Also, the current selection should be passed as input parameters to the transaction.
In my example, I am trying to run the transaction /SAPAPO/MC90 - Release to Supply Network Planning from the Demand Planning Planning Book/Data View. This way if planners need to change forecasts mid month for specific selections, they can easily transfer to SNP without having to go out of interactive planning.
Thank you,
MariaHello Maria,
It's possible to call a transaction from a planning book using a macro button.
What you can do is ..... Create a function module and inside it use the command "Call Transaction Tcode" (ABAPer can do this) to call ur specific transaction. And this module can in turn be called from your macro. Please find the below link which explanis how to call a function module from a macro. Do let me know if you need more information on this.
Calling a function module from APO Macro
Regards,
Siva. -
Removal of sub-menus from selection-screen....
Hi experts,
When I click on the Test (F8) button in my report. It navigates to the selection-screen. Here in selection-screen, I can see various menus in menu bar like 'Program' , 'Edit' , 'Goto', 'System' and 'Help'. Menu 'Program' has few sub-menus like 'Execute', 'Execute and print' , 'Execute in background' and exit. In my report I dont want the sub-menus 'Execute and print' and 'Execute in background' to appear. So please tell me how to delete these sub-menus feom selection-screen.
Do I need changes it from the PF-STATUS?
Regards,
SachinHi,
I dont think that u can do that in selection Screen. Because screen 1000 is reserved for selection Screen
and u can't change the menu items.
U can do on thing. U create a custom screen like selection Screen and call that instead of Selection Screen.
Regards
Sandipan -
Problem in getting parameter value from selection screen in web dynpro abap
Hi,
I am facing problem in getting parameter value from selection screen.
Please find my code below:
DATA LT_PAR_ITEM TYPE IF_WD_SELECT_OPTIONS=>TT_SELECTION_SCREEN_ITEM.
FIELD-SYMBOLS:<FS_PAR_ITEM> LIKE LINE OF LT_PAR_ITEM,
<FS_OBJ_USAGE> TYPE REF TO data.
WD_THIS->M_HANDLER->GET_PARAMETER_FIELDS( IMPORTING ET_FIELDS = LT_PAR_ITEM ).
LOOP AT LT_PAR_ITEM ASSIGNING <FS_PAR_ITEM>.
CASE <FS_PAR_ITEM>-M_ID.
WHEN `OBJ_USAGE`.
ASSIGN <FS_PAR_ITEM>-M_VALUE->* TO <FS_OBJ_USAGE>.
[ Here, sy-subrc is 4, <FS_OBJ_USAGE> is not assigning.]
ENDCASE.
ENDLOOP.
So, can any one solve this problem.
Thanks in advance,
RadhikaHi Radhika,
Try using GET_RANGE_TABLE_OF_SEL_FIELD...
Please Refer below code..
DATA: NODE_FLIGHTS TYPE REF TO IF_WD_CONTEXT_NODE.
DATA: RT_CARRID TYPE REF TO DATA.
DATA: ISFLIGHT TYPE TABLE OF SFLIGHT.
DATA: WSFLIGHT TYPE SFLIGHT.
FIELD-SYMBOLS: <FS_CARRID> TYPE TABLE.
Retrieve the data from the select option
RT_CARRID = WD_THIS->M_HANDLER->GET_RANGE_TABLE_OF_SEL_FIELD( I_ID = 'S_CARR_ID' ).
Assign it to a field symbol
ASSIGN RT_CARRID->* TO <FS_CARRID>.
CLEAR ISFLIGHT. REFRESH ISFLIGHT.
SELECT * INTO CORRESPONDING FIELDS OF TABLE ISFLIGHT FROM SFLIGHT
WHERE CARRID IN <FS_CARRID>.
NODE_FLIGHTS = WD_CONTEXT->GET_CHILD_NODE( NAME = `FLIGHTS` ).
NODE_FLIGHTS->BIND_ELEMENTS( ISFLIGHT ).
Thanks,
Regards,
Kiran -
Calling SAP Transaction from BSP
I wonder whether it is possible to call SAP transaction from BSP application and pass to it some data; e.g., PO# when calling VA02?
The called transaction could appear in a separate MS IE Window (like in some Portal applications) or in SAP GUI.
Any help will be appreciated.
Thank you in advanceI have launched the Java SAPGui from BSP pages before. I used SNC so that the users were logged on via Single Sign On. I store the Java Gui in the Mime directory. You can force the startup transaction. Theorectically you could also Gui Scripting to try and control the Gui and force in the default value for your PO field. I have not tried that however. You will probably want to check the Service Marketplace for documents on the Gui Scripting. The following is the code from my BSP page to launch the Java Gui in the Browser as an applet:
<%@page language="abap"%>
<%@extension name="htmlb" prefix="htmlb"%>
<HTML>
<HEAD>
<TITLE>SAPGUI for the Java Environment</TITLE>
<STYLE type="text/css">
body { margin-left:0px; margin-right:0px; margin-top:0px; margin-bottom:0px; }
</STYLE>
</HEAD>
<BODY scroll="no">
<SCRIPT language="JavaScript">
// user configurable part starts here
var pluginurl = '';
var scriptable = 'true';
var codebase = '.';
var jnlp = 'platin.jnlp';
var keepalive = 'true';
var frog = 'true';
var trace = '';
var tracefile = '';
var connectionData = 'conn=/M/nts163/S/3620/G/SPACE/&tran=SE80&clnt=088&fast=true&sncon=true&sncname=p:[email protected]&sncqop=9';
// user configurable part ends here
// verify if Java Plugin as control in Internet Explorer or Java Plugin for Netscape or native JRE of browser must be used
var jre = 'control';
if(navigator.platform.indexOf("Mac") > -1)
jre = 'native';
else if (navigator.appName.indexOf("Netscape") != -1)
jre = 'plugin';
document.open();
switch (jre)
case 'control':
document.writeln('<OBJECT CLASSID = "clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" ');
document.writeln(' ID = "PlatinGUI" ');
document.writeln(' CODEBASE = "j2re-1_3_1_02-win-i.exe#Version=1,3,1,0" ');
document.writeln(' WIDTH = "100%" ');
document.writeln(' HEIGHT = "100%" ');
document.writeln(' BORDER = 0> ');
document.writeln('<PARAM NAME = "TYPE" VALUE = "application/x-java-applet;jpi-version=1.3.1"> ');
document.writeln('<PARAM NAME = "SCRIPTABLE" VALUE = "', scriptable,'"> ');
document.writeln('<PARAM NAME = "code" VALUE = "com.sap.platin.GuiApplet2"> ');
document.writeln('<PARAM NAME = "codebase" VALUE = "', codebase,'"> ');
document.writeln('<PARAM NAME = "jnlp" VALUE = "', jnlp,'"> ');
document.writeln('<PARAM NAME = "archive" VALUE = "GuiStartS.jar"> ');
document.writeln('<PARAM NAME = "keepalive" VALUE = "', keepalive,'"> ');
document.writeln('<PARAM NAME = "frog" VALUE = "', frog,'"> ');
document.writeln('<PARAM NAME = "trace" VALUE = "', trace,'"> ');
document.writeln('<PARAM NAME = "tracefile" VALUE = "', tracefile,'"> ');
document.writeln('<PARAM NAME = "connectionData" VALUE = "', connectionData,'"> ');
document.writeln(' ');
document.writeln('This page requires a Sun Java Plugin 1.3 and a SAPGUI for Java to view. ');
document.writeln(' ');
document.writeln('</OBJECT> ');
break;
case 'plugin':
document.writeln('<EMBED TYPE = "application/x-java-applet;version=1.3" ');
document.writeln(' PLUGINURL = "', pluginurl,'" ');
document.writeln(' WIDTH = "100%" ');
document.writeln(' HEIGHT = "100%" ');
document.writeln(' ALIGN = "BASELINE" ');
document.writeln(' code = "com.sap.platin.GuiApplet2" ');
document.writeln(' codebase = "', codebase,'" ');
document.writeln(' jnlp = "', jnlp,'" ');
document.writeln(' archive = "GuiStartS.jar" ');
document.writeln(' keepalive = "', keepalive,'" ');
document.writeln(' frog = "', frog,'" ');
document.writeln(' trace = "', trace,'" ');
document.writeln(' tracefile = "', tracefile,'" ');
document.writeln(' connectionData = "', connectionData,'" ');
document.writeln(' <NOEMBED> ');
document.writeln(' </NOEMBED> ');
document.writeln(' </EMBED> ');
break;
case 'native':
document.writeln('<APPLET CODEBASE = "', codebase,'" ');
document.writeln(' ARCHIVE = "GuiStartS.jar" ');
document.writeln(' CODE = "com.sap.platin.GuiApplet2" ');
document.writeln(' WIDTH = "100%" ');
document.writeln(' HEIGHT = "100%"> ');
document.writeln('<PARAM NAME = "SCRIPTABLE" VALUE = "', scriptable, '"> ');
document.writeln('<PARAM NAME = "jnlp" VALUE = "', jnlp, '"> ');
document.writeln('<PARAM NAME = "keepalive" VALUE = "', keepalive, '"> ');
document.writeln('<PARAM NAME = "frog" VALUE = "', frog, '"> ');
document.writeln('<PARAM NAME = "trace" VALUE = "', trace, '"> ');
document.writeln('<PARAM NAME = "tracefile" VALUE = "', tracefile, '"> ');
document.writeln('<PARAM NAME = "connectionData" VALUE = "', connectionData, '"> ');
document.writeln('</APPLET> ');
break;
document.close();
</SCRIPT>
</BODY>
</HTML> -
Can we call another transaction from the Userexit
Hi all,
Can we call another transaction from the Userexit?
Thanks,
BalajiHi
Because the statament CALL TRANSACTION triggers the end of the LUW so COMMIT WORK, so you should be sure not to insert that statament while some updating actions are been doing.
So that exit shouldn't be triggered while updating
Max -
Call sap transaction from java
can anyone tell me how to call SAP transaction from JCO,
cheers
AjayHi Ajay,
You should find or create functional module which covers your requrements.
Best regards, Maksim Rashchynski. -
Problem with the selection screen in submit program
Hi Friends,
i am facing the problem wih the selection screen in submit program. in my Module pool program i am using the submit program statement, When i execute the program , The module program display the submit program selections creen.
I have implemented the code same as below.
submit ztest with tknum =p_tknum and return.
Can you pleaes help me how to avoid the submit program selection screen.
Thanks,
CharanHi Charan,
You have to give the selection screen values when you submit a job.
Press F1 on submit and you will see more details.
Here is an example from ABAP Documentation.
Program accessed
REPORT report1.
DATA text(10) TYPE c.
SELECTION-SCREEN BEGIN OF SCREEN 1100.
SELECT-OPTIONS: selcrit1 FOR text,
selcrit2 FOR text.
SELECTION-SCREEN END OF SCREEN 1100.
Calling program
REPORT report2.
DATA: text(10) TYPE c,
rspar_tab TYPE TABLE OF rsparams,
rspar_line LIKE LINE OF rspar_tab,
range_tab LIKE RANGE OF text,
range_line LIKE LINE OF range_tab.
rspar_line-selname = 'SELCRIT1'.
rspar_line-kind = 'S'.
rspar_line-sign = 'I'.
rspar_line-option = 'EQ'.
rspar_line-low = 'ABAP'.
APPEND rspar_line TO rspar_tab.
range_line-sign = 'E'.
range_line-option = 'EQ'.
range_line-low = 'H'.
APPEND range_line TO range_tab.
range_line-sign = 'E'.
range_line-option = 'EQ'.
range_line-low = 'K'.
APPEND range_line TO range_tab.
SUBMIT report1 USING SELECTION-SCREEN '1100'
WITH SELECTION-TABLE rspar_tab
WITH selcrit2 BETWEEN 'H' AND 'K'
WITH selcrit2 IN range_tab
AND RETURN.
Regards,
Jovito. -
Selection-screen in module program
Hi,
I have created a module pool prog.
Now the new regd. is that I want to create selection-screen before displying the actual screen.
But when I m trying to use selection screen then I m getting the message that it is not possible in type 'M' as my program is module pool.
I m using screen 9000 to display the records, now where to write selection screen in the program?
I think in PBO but getting some error, I have created one screen and in that defined a subscreen but it is giving some error.
So any body knows how to add selection screen in 'M' type program?
Thankx in advance.
UmeshHi,
You can create a selection-screen for a module pool program.
Create a new program with executable type. Create the selection screen as you would do in a normal program. Once you give data in the selection and press F8 button, based on the logics written, the O/P must appear in a table control. This is what your requirement is:
A example below for your understanding.
name of the prog : ZTEST
Type: Exectable report (I)
*----Selection Screen -
SELECTION-SCREEN BEGIN OF BLOCK IPDATA WITH FRAME TITLE TEXT-001.
PARAMETERS: PR_MONTH LIKE BOITEM-SPMON.
SELECT-OPTIONS: SO_VKGRP FOR KNVV-VKGRP.
SELECTION-SCREEN END OF BLOCK IPDATA.
SELECTION-SCREEN BEGIN OF BLOCK ORGDATA WITH FRAME TITLE TEXT-002.
SELECT-OPTIONS: SO_REGIO FOR KNA1-REGIO,
SO_KUNNR FOR KNA1-KUNNR,
SO_WERKS FOR T001W-WERKS.
SELECTION-SCREEN END OF BLOCK ORGDATA.
*--Selection Screen Events--
START-OF-SELECTION.
W_CURMFDAY = SY-DATUM.
W_CURMFDAY+6(2) = '01'.
PERFORM F001_GETDATA.
IF SY-DBCNT EQ 0.
MESSAGE S017(ZSFL).
EXIT.
ENDIF.
PERFORM F002_ADDITIONALDATA.
CALL SCREEN 100.
For this screen 100, both the PBO and PAI can be declared in this main program itself.
Regards,
JLN. -
Can I make two differents selection screen in my program?
Hi experts!!
I don't know how to male this, the problem is that I need to make two differents selection screen in my program because I have two differents kinds of button,
BUTTON1 BUTTON2 BUTTON3
When I press button1 I received.
BUTTON4 BUTTON5 BUTTON6
Now If I press on button4, how can I pick up the event? the name or something associate to this button4?
Thanks a lot and regards
RebecaHi and thanks,
I've tried with your code, Velu Lakshmanan, and I only received another screen with the buttons... I need to put this button in the same screen, now I've this, but I can't receive the event associate to the second's buttons,
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN PUSHBUTTON 1(79) DTP USER-COMMAND DTP
VISIBLE LENGTH 25.
SELECTION-SCREEN PUSHBUTTON 28(79) EMP USER-COMMAND EMP
VISIBLE LENGTH 25.
SELECTION-SCREEN PUSHBUTTON 55(79) ABS USER-COMMAND ABS
VISIBLE LENGTH 25.
PARAMETERS: PROC_TYP TYPE I DEFAULT 1 NO-DISPLAY.
SELECTION-SCREEN END OF LINE.
* Informes de datos de tiempo.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN PUSHBUTTON 1(25) TEXT-FED USER-COMMAND FED MODIF ID DT1.
SELECTION-SCREEN PUSHBUTTON 28(25) TEXT-DCH USER-COMMAND DCH MODIF ID DT1.
SELECTION-SCREEN PUSHBUTTON 55(25) TEXT-ACH USER-COMMAND ACH MODIF ID DT1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN PUSHBUTTON 1(25) TEXT-FII USER-COMMAND FII MODIF ID DT1.
SELECTION-SCREEN PUSHBUTTON 28(25) TEXT-PTB USER-COMMAND PTB MODIF ID DT1.
SELECTION-SCREEN PUSHBUTTON 55(25) TEXT-PTS USER-COMMAND PTS MODIF ID DT1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN PUSHBUTTON 1(25) TEXT-ACI USER-COMMAND ACI MODIF ID DT1.
SELECTION-SCREEN PUSHBUTTON 28(25) TEXT-FIM USER-COMMAND FIM MODIF ID DT1.
SELECTION-SCREEN PUSHBUTTON 55(25) TEXT-LDH USER-COMMAND LDH MODIF ID DT1.
SELECTION-SCREEN END OF LINE.
* Informes de empleados
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN PUSHBUTTON 1(25) TEXT-LDP USER-COMMAND LDP MODIF ID EM1.
SELECTION-SCREEN PUSHBUTTON 28(25) TEXT-PDF USER-COMMAND PDF MODIF ID EM1.
SELECTION-SCREEN PUSHBUTTON 55(25) TEXT-LDT USER-COMMAND LDT MODIF ID EM1.
SELECTION-SCREEN END OF LINE.
* Informes de bajas
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN PUSHBUTTON 1(25) TEXT-BAJ USER-COMMAND BAJ MODIF ID AB1.
SELECTION-SCREEN PUSHBUTTON 28(25) TEXT-VMA USER-COMMAND VMA MODIF ID AB1.
SELECTION-SCREEN PUSHBUTTON 55(25) TEXT-SDE USER-COMMAND SDE MODIF ID AB1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN PUSHBUTTON 1(25) TEXT-LDB USER-COMMAND LDB MODIF ID AB1.
SELECTION-SCREEN PUSHBUTTON 28(25) TEXT-LDA USER-COMMAND LDA MODIF ID AB1.
SELECTION-SCREEN PUSHBUTTON 55(25) TEXT-DHT USER-COMMAND DHT MODIF ID AB1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK B1.
* Pintamos los botones que necesitemos mostrar según la opción seleccionada
AT SELECTION-SCREEN.
CASE SSCRFIELDS-UCOMM.
WHEN 'DTP'. PROC_TYP = 1.
WHEN 'EMP'. PROC_TYP = 2.
WHEN 'ABS'. PROC_TYP = 3.
ENDCASE.
AT SELECTION-SCREEN OUTPUT.
CASE PROC_TYP.
* Cuando el botón que ha seleccionado es "Datos de tiempo"
WHEN 1.
CALL FUNCTION 'ICON_CREATE'
EXPORTING
NAME = ICON_OKAY
TEXT = TEXT-DTP
INFO = TEXT-AUS
IMPORTING
RESULT = DTP.
EMP = TEXT-EMP.
ABS = TEXT-ABS.
LOOP AT SCREEN.
IF SCREEN-GROUP1 EQ 'DT1'.
SCREEN-INPUT = '1'. SCREEN-INVISIBLE = '0'. MODIFY SCREEN.
ENDIF.
IF SCREEN-GROUP1 EQ 'EM1'.
SCREEN-INPUT = '0'. SCREEN-INVISIBLE = '1'. MODIFY SCREEN.
ENDIF.
IF SCREEN-GROUP1 EQ 'AB1'.
SCREEN-INPUT = '0'. SCREEN-INVISIBLE = '1'. MODIFY SCREEN.
ENDIF.
ENDLOOP.
WHEN 2.
CALL FUNCTION 'ICON_CREATE'
EXPORTING
NAME = ICON_OKAY
TEXT = TEXT-EMP
INFO = TEXT-AUS
IMPORTING
RESULT = EMP.
DTP = TEXT-DTP.
ABS = TEXT-ABS.
LOOP AT SCREEN.
IF SCREEN-GROUP1 EQ 'DT1'.
SCREEN-INPUT = '0'. SCREEN-INVISIBLE = '1'. MODIFY SCREEN.
ENDIF.
IF SCREEN-GROUP1 EQ 'EM1'.
SCREEN-INPUT = '1'. SCREEN-INVISIBLE = '0'. MODIFY SCREEN.
ENDIF.
IF SCREEN-GROUP1 EQ 'AB1'.
SCREEN-INPUT = '0'. SCREEN-INVISIBLE = '1'. MODIFY SCREEN.
ENDIF.
ENDLOOP.
WHEN 3.
CALL FUNCTION 'ICON_CREATE'
EXPORTING
NAME = ICON_OKAY
TEXT = TEXT-ABS
INFO = TEXT-AUS
IMPORTING
RESULT = ABS.
DTP = TEXT-DTP.
EMP = TEXT-EMP.
LOOP AT SCREEN.
IF SCREEN-GROUP1 EQ 'DT1'.
SCREEN-INPUT = '0'. SCREEN-INVISIBLE = '1'. MODIFY SCREEN.
ENDIF.
IF SCREEN-GROUP1 EQ 'EM1'.
SCREEN-INPUT = '0'. SCREEN-INVISIBLE = '1'. MODIFY SCREEN.
ENDIF.
IF SCREEN-GROUP1 EQ 'AB1'.
SCREEN-INPUT = '1'. SCREEN-INVISIBLE = '0'. MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDCASE.
Help please... I don't know how can I make this.....
If I use screen...how can I put this screen in the correct place?
Thanks a lot
Regards,
Rebeca
Maybe you are looking for
-
How to have new Safari windows open in full screen?
Hello, I am wondering if it is possible to have new Safari windows take up the full screen. For example, if I click on a link that opens a new window, I would like that new window to take on the fully maximized setting of the window it came from. So
-
For several months, when i use iTunes or Adobe, my mac osx Snow Leopard, does not close automatically, I doid use the power button. I tried a command on the terminel by : fsck)and yf . I received this message " The volume appaers to be OK. Then I ent
-
Task not coming in Open Provisioning Task when Request is raised(OIM 9i)
Hi When ever i am assigning the task to group that task is not getting updated in the open provisioning tasks. I i assign the task to xelsysadm instead of the group i am able to see the task in open provisioning tasks. I thought its permission issue
-
Export Settings - Minimum Bit Rate Question (MPEG2-DVD)
Hi, Curious...just came over recently from FCP and I don't remember Compressor giving me an option to adjust the MINIMUM bit rate when exporting HD projects for DVD. I figured I'd just leave it where the preset has it (at 2.8mbps minimum)...BUT...the
-
How to setup database trace on odata service
I have found two discussion which mention that we have to setup database trace but how is the question? if some one can please help me out step by step setting up the trace on odata service, links are as follows Manage multi-table insert using OData