<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to delay background processing in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-delay-background-processing/m-p/1083237#M98475</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be this will Help.. try  &lt;/P&gt;&lt;P&gt;WIth Job may be you can specify time..&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt; SUBMIT REPORTNAME AND RETURN
USER SY-UNAME " User for runtime authorizations
VIA JOB JOBNAME NUMBER JOBNUMBER
" Job name and job number
" from JOB_OPEN
TO SAP-SPOOL " Print and archiving options from
" GET_PRINT_PARAMETERS
" Both sets of options come from
" GET_PRINT_PARAMETERS
SPOOL PARAMETERS USER_PRINT_PARAMS
ARCHIVE PARAMETERS USER_ARC_PARAMS
WITHOUT SPOOL DYNPRO.
Leaving content frame&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 11 Dec 2005 09:31:29 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2005-12-11T09:31:29Z</dc:date>
    <item>
      <title>How to delay background processing</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-delay-background-processing/m-p/1083236#M98474</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am writing a submit statement in the Delivery Order exit USEREXIT_SAVE_DOCUMENT_PREPARE. It triggers on saving the Delivery.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The submit statement calls my Z Program in background (Im using Job Open and Job Close).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My requirement is that once the submit statement is executed, the cursor should come back to my driver program (User exit) and save the delivery document.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The background Z program should get triggered after say 5 minutes only on the condition that a delivery document exists for the particular delivery.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could someone tell me how to write the SUBMIT statement to send my z program in background and ask it to start/release after a lag of 5 minutes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Shobhit&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Dec 2005 09:09:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-delay-background-processing/m-p/1083236#M98474</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-12-11T09:09:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to delay background processing</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-delay-background-processing/m-p/1083237#M98475</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be this will Help.. try  &lt;/P&gt;&lt;P&gt;WIth Job may be you can specify time..&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt; SUBMIT REPORTNAME AND RETURN
USER SY-UNAME " User for runtime authorizations
VIA JOB JOBNAME NUMBER JOBNUMBER
" Job name and job number
" from JOB_OPEN
TO SAP-SPOOL " Print and archiving options from
" GET_PRINT_PARAMETERS
" Both sets of options come from
" GET_PRINT_PARAMETERS
SPOOL PARAMETERS USER_PRINT_PARAMS
ARCHIVE PARAMETERS USER_ARC_PARAMS
WITHOUT SPOOL DYNPRO.
Leaving content frame&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Dec 2005 09:31:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-delay-background-processing/m-p/1083237#M98475</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-12-11T09:31:29Z</dc:date>
    </item>
    <item>
      <title>Re: How to delay background processing</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-delay-background-processing/m-p/1083238#M98476</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Shobhit,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  Try the below way. Pass what time you want to start the&lt;/P&gt;&lt;P&gt;  job(time &amp;amp; Date ) to job close.&lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
IF V_DATE &amp;gt; SY-DATUM OR
     ( V_DATE = SY-DATUM AND V_TIME &amp;gt;= SY-UZEIT ).
    CALL FUNCTION 'JOB_CLOSE'
         EXPORTING
              JOBCOUNT             = V_JOBNUMBER
              JOBNAME              = V_JOBNAME
              SDLSTRTDT            = V_DATE
              SDLSTRTTM            = V_TIME
              TARGETSYSTEM         = SY-HOST
         IMPORTING
              JOB_WAS_RELEASED     = V_REL
         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.

  &lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Dynamically if you want to give option to user when to&lt;/P&gt;&lt;P&gt;schdule job use the below and pass the particular time and date.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
 CLEAR I_HELPVAL.
  REFRESH I_HELPVAL.

  I_HELPVAL-LENGTH = 8.
  I_HELPVAL-KEYWORD = 'DATE ( YYYYMMDD )'.
  I_HELPVAL-VALUE = SY-DATUM.
  APPEND I_HELPVAL.

  I_HELPVAL-LENGTH = 6.
  I_HELPVAL-KEYWORD = 'TIME ( HHMMSS )'.
  I_HELPVAL-VALUE = SY-UZEIT.
  APPEND I_HELPVAL.

  CALL FUNCTION 'HELP_GET_VALUES'
       EXPORTING
            POPUP_TITLE = 'Batch Job - Enter Date and Time'(023)
       IMPORTING
            RETURNCODE  = V_REL
       TABLES
            FIELDS      = I_HELPVAL
       EXCEPTIONS
            NO_ENTRIES  = 1
            OTHERS      = 2.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this is useful.&lt;/P&gt;&lt;P&gt;Thanks&amp;amp;Regards,&lt;/P&gt;&lt;P&gt;Siri.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Dec 2005 09:52:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-delay-background-processing/m-p/1083238#M98476</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-12-11T09:52:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to delay background processing</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-delay-background-processing/m-p/1083239#M98477</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Srilatha!!! &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Shobhit&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 11 Dec 2005 14:00:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-delay-background-processing/m-p/1083239#M98477</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-12-11T14:00:52Z</dc:date>
    </item>
  </channel>
</rss>

