Application Development 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: 

How to avoid popup message in 'submit' sentence?

Former Member
0 Kudos

When submit a report, if there is popup message in report, the caller program will appear this, Is there any way the avoid this?

By the way, there is logic to determine backgroud or online in this report, if background the popup message will not appear. But I set sy-batch = 'X' before submit report, the system still take it as online, and popup message appeared.

Any help is appreciated.

9 REPLIES 9

Former Member
0 Kudos

hi

is this one useful SUPPRESS DIALOG

sasi

Former Member
0 Kudos

How to use it? Before submit?

Former Member

0 Kudos

Hi,

try:

1) fm job_open

2) submit report

3) fm job_close

example:

 DATA: jobcount_test LIKE tbtcjob-jobcount,
        job_released    LIKE btch0000-char1,
        rcode(2),
        strtimmed LIKE btch0000-char1 VALUE 'X'.
  DATA jobname  LIKE tbtcjob-jobname.

  CONCATENATE  'TEST_' sy-repid '_' sy-datum INTO jobname.

  CALL FUNCTION 'JOB_OPEN'
       EXPORTING
            jobname          = jobname
       IMPORTING
            jobcount         = jobcount_test
       EXCEPTIONS
            cant_create_job  = 1
            invalid_job_data = 2
            jobname_missing  = 3
            OTHERS           = 4.


  IF sy-subrc NE 0.
    MESSAGE x000(yp) WITH 'JOB-START ' jobname ' failed !!!'.
  ELSE.
*--Step insert
    SUBMIT rsbdcsub
    USER sy-uname VIA JOB jobname NUMBER jobcount_test
    WITH mappe = map
    WITH von = pdatum
    WITH z_verarb = 'X'
    AND RETURN .
*
    CALL FUNCTION 'JOB_CLOSE'
         EXPORTING
              jobcount             = jobcount_test
              jobname              = jobname
              strtimmed            = strtimmed
              targetsystem         = sy-host
         IMPORTING
              job_was_released     = job_released
         EXCEPTIONS
              cant_start_immediate = 1
              invalid_startdate    = 2
              jobname_missing      = 3
              job_close_failed     = 4
              job_nosteps          = 5
              job_notex            = 6
              lock_failed          = 7
              OTHERS               = 8.
    IF sy-subrc > 1.
      MESSAGE x000(yp) WITH 'JOB-CLOSE ' jobname ' failed!!!'.
    ENDIF.
  ENDIF.

regards Andreas

Former Member
0 Kudos

I tried to use submit as background job, but it also appear popup message and stop in there!

Former Member
0 Kudos

tried. but when entered in the report, the sy-batch still = null, so popup still appear!!

Former Member
0 Kudos

hi, Paul

You can try the following code, there are two application, one is for print a sy-batch to screen, the other is creating a job and call the former.


* first application
REPORT ZGZL_SDNTEST24.

PARAMETER: BATCH LIKE SY-BATCH.
WRITE: 'SY-BATCH:', SY-BATCH.

* second application
REPORT ZGZL_SDNTEST25.

DATA: TBTCJOB  TYPE  TBTCJOB.

TBTCJOB-AUTHCKNAM = SY-UNAME.
CALL FUNCTION 'JOB_OPEN'
     EXPORTING
          JOBNAME  = 'ZGZL_SDNTEST24'
     IMPORTING
          JOBCOUNT = TBTCJOB-JOBCOUNT
     EXCEPTIONS
          OTHERS   = 01.
IF SY-SUBRC = 0.
  SUBMIT ZGZL_SDNTEST24
         VIA
         JOB 'ZGZL_SDNTEST24'
         NUMBER TBTCJOB-JOBCOUNT
         TO SAP-SPOOL
           DESTINATION 'LP01'
           KEEP IN SPOOL ' '
           IMMEDIATELY 'X'
           WITHOUT SPOOL DYNPRO
         AND RETURN.

  IF SY-SUBRC = 0.
    CALL FUNCTION 'JOB_CLOSE'
         EXPORTING
              JOBNAME   = 'ZGZL_SDNTEST24'
              JOBCOUNT  = TBTCJOB-JOBCOUNT
              STRTIMMED = 'X'
         EXCEPTIONS
              OTHERS    = 01.
  ENDIF.
ENDIF.

hope it will be helpful

thanks

0 Kudos

Hi, I have the Same Problem... I'm calling a LIS UPDATE PROGRAM for LIS TABLES....


Each time I submitted, 3 POP-UPs were show .

So far, I found only two ways to suppress it:

1- To create a transaction to the programs, and called it via CALL TRANSACTION in MODE "N".

2- If you do not want to create a transaction, create an EVENT (SM62) then a Scheduled Job (SM36) and set an EVENT... then you can use the FM 'BP_EVENT_RAISE' and the job will ran.

Scheduling background job by triggering an event - ABAP Development - SCN Wiki

PS: Also I used JOB_OPEN / JOB_CLOSE and I get to suppress 2 of 3 pop-up messages, the first one was impossible to me... 

0 Kudos

Hi, I had the same problem... I'm calling a LIS UPDATE PROGRAM for LIS TABLES....


Each time I submitted, 3 POP-UPs were show .

So far, I found only two ways to suppress it:

1- To create a transaction to the programs, and called it via CALL TRANSACTION in MODE "N".

2- If you do not want to create a transaction, create an EVENT (SM62) then a Scheduled Job (SM36) and set an EVENT... then you can use the FM 'BP_EVENT_RAISE' and the job will ran.

Scheduling background job by triggering an event - ABAP Development - SCN Wiki

PS: Also I used JOB_OPEN / JOB_CLOSE and I get to suppress 2 of 3 pop-up messages, the first one was impossible to me...