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

Submit function

Former Member
0 Likes
935

Hi friends....

I am running a zreport: zpmu_hcc_tcmm_interface, in which i have to call another report

zmm70r_mm_pf_audit .

The input parameters to the program(zmm70r_mm_pf_audit) are division,sales organisation and distribution channel, and these fields are generated in the program zpmu_hcc_tcmm_interface itself.

Can any one suggest me how to pass these input paramers to the zprogram(zmm70r_mm_pf_audit) and get back the list to the zpmu_hcc_tcmm_interface?

Thanks & regards,

Latha

8 REPLIES 8
Read only

Former Member
0 Likes
855

Hi

Use below syntax of SUBMIT statement

SUBMIT program name

WITH PA_TEST =

WITH SO_TEST

AND RETURN.

create the same parameters inthe report program to which u are submitting

BR

lavanya

Edited by: Lavanya K on Aug 11, 2008 2:53 PM

Read only

Former Member
0 Likes
855

Hi.

Calling a Z program with parameters:

SUBMIT ZPPO_LABELS_OUTPUT

WITH P_ARBPL = I_ARBPL

WITH P_MATNR = I_MATNR

WITH P_AUFNR = I_AUFNR

WITH P_SERNR = I_SERNR AND RETURN.

Get the second progrsm's output has to be done threw export to the external memory and import it back after the above command.

Regards, Rebeka

Read only

Former Member
0 Likes
855

try to use

*Submit report and return to current program afterwards

SUBMIT zreport AND RETURN.

*Submit report via its own selection screen

SUBMIT zreport VIA SELECTION-SCREEN.

*Submit report using selection screen variant

SUBMIT zreport USING SELECTION-SET 'VARIANT1'.

*Submit report but export resultant list to memory, rather than

*it being displayed on screen

SUBMIT zreport EXPORTING LIST TO MEMORY.

  • Once report has finished and control has returned to calling

  • program, use function modules LIST_FROM_MEMORY, WRITE_LIST and

  • DISPLAY_LIST to retrieve and display report.

*Example Code (Retrieving list from memory)

DATA BEGIN OF itab_list OCCURS 0.

INCLUDE STRUCTURE abaplist.

DATA END OF itab_list.

DATA: BEGIN OF vlist OCCURS 0,

filler1(01) TYPE c,

field1(06) TYPE c,

filler(08) TYPE c,

field2(10) TYPE c,

filler3(01) TYPE c,

field3(10) TYPE c,

filler4(01) TYPE c,

field4(3) TYPE c,

filler5(02) TYPE c,

field5(15) TYPE c,

filler6(02) TYPE c,

field6(30) TYPE c,

filler7(43) TYPE c,

field7(10) TYPE c,

END OF vlist.

SUBMIT zreport EXPORTING LIST TO MEMORY.

CALL FUNCTION 'LIST_FROM_MEMORY'

TABLES

listobject = itab_list

EXCEPTIONS

not_found = 4

OTHERS = 8.

Read only

Former Member
0 Likes
855

Hi,

Try the below submit statement.

SUBMIT <your Executable Report Name> WITH SELECTION-TABLE <target report selection screen data> AND RETURN..

Example:

data: it_selection type table of rsparams,

wa_selection like line of rspar_tab.

SUBMIT zb_set WITH SELECTION-TABLE it_selection

AND RETURN.

Check the F1 help for SUBMIT Statement.

Regards,

Boobalan S.

Read only

Former Member
0 Likes
855

Check out this code



REPORT 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.

http://abap-explorer.blogspot.com/

Read only

Former Member
0 Likes
855

Hi Friend,

Code will be like:

SUBMIT <PROG NAME> WITH P1 = <PARA1> P2 = <PARA2> EXPORT LIST TO MEMORY AND RETURN.

Use LIST_FROM_MEMORY and WRITE_LIST to write on a screen.

Hope it will help you.

Regards

Krishnendu

Read only

Former Member
0 Likes
855

Hi,

Check the following link:

http://help.sap.com/search/highlightContent.jsp

Regards

Bhaskar

Read only

Former Member
0 Likes
855

Hi Vidyullatha,

The submit statement syntax will be like this, pls have a look at the sample code

SUBMIT demo_program_submit_rep1 VIA SELECTION-SCREEN

WITH paramet eq 'Selection 1'

WITH selecto IN seltab

WITH selecto ne 3

AND RETURN.

Regards,

Suresh.S