Call another program in first program

hi,
i need to perform to call another report in my current report. so how am i going to do so?
how report work:
the report are going to run as background job. once the report run, it will send out the report in text file to user. and then i want it to trigger report 2. report 2 work the same, it will send another text file to user.
and the parameter for both the report is on current date only.
so how am i going to code in my first report program, to call the second report program, and to execute it?
thanks
Edited by: ben leen lee on May 14, 2008 3:57 AM

Hi, 
clear: d_JOB_COUNT.
    CALL FUNCTION 'JOB_OPEN'
      EXPORTING
        JOBNAME  = d_JOBNAME
      IMPORTING
        JOBCOUNT = d_JOB_COUNT.
    submit ZFI_AGEWISE_PERFORMANCE
    VIA JOB d_JOBNAME
    NUMBER  d_JOB_COUNT
    with IKUNNR   IN r_id
    with s_vertn  in S_VERTN
    with s_hkont  IN S_HKONT
    with IBUDAT   eq IBUDAT
    with P_BUKRS  eq P_BUKRS
    with s_umskz  in s_umskz
*with R1 = R1
    WITH R2 = R2
*with r3 = R3
    WITH P_SESS = P_SESS
    AND RETURN.
    CALL FUNCTION 'JOB_CLOSE'
      EXPORTING
        JOBNAME      = d_JOBNAME
        JOBCOUNT     = d_JOB_COUNT
        STRTIMMED    = 'X'.
Reward Points

Similar Messages

  • Calling another transaction in Dialog Programming

    Hello ppl,
    How can I call another transaction(ZPROGRAM2) from my transaction(ZPROGRAM1) using the delivery and the check box options selected in Screen Programming. Should I use BDC.? Also in case of any errors in ZPROGRAM2, the control should return to ZPROGRAM1 with all the previous setting retained.
    Thanks a lot.
    Karthikeyan

    Hi ,
    You can try with BDC as you need to get the control back to the program1.
    If not you can try with the SUBMIT statement.
    ex:-
    SUBMIT zrslg0000  EXPORTING LIST TO MEMORY
                  AND RETURN.
    Regards,
    Satish

  • Need to call another progarm in Zdriver program for a specific output type

    For billing document they had configured a Zdriver program and Zsmart form in Nace.
    Now, we had created an output type and when user clicks on that specific output type my ZXYZ program should run.
    ZXYZ program will convert the spool request into .pdf files.
    So what I had done is I have given a condition in Zdriver program saying that If output type is ZD0p.
    Submit ZXYZ program so that this program will automatically run.
    I just want to make sure that is it the right way I mean shoudl I add something else to the Submit statement...here
    and can any one tell me how can I generate spool request by giveing a billing document number in VF02--> Click on Enter > Click on Header>Click on Output-->Enter the Output type and give the communication method details and click on Save...will this generate the spool request..?

    Hi
    and can any one tell me how can I generate spool request by giveing a billing document number in VF02--> Click on Enter --> Click on Header-->Click on Output-->Enter the Output type and give the communication method details and click on Save...will this generate the spool request..
    After doing the whole porcess...re enter the vfo2 transacrion, give the document number and in Menu..Under "Billing Document"..Select issue output to...and there select the output type..and select Print button, it will generate spool request.
    Regards,
    Vishwa.

  • Calling another person after first call is finished

    Hi all,
    I think there is problem with my Iphone... Actually after I call a person if i want to call any other person then my phone is getting stuck and is taking time to come back to normal position....
    And if on the other end it goes to voice mail then its the biggest problem....
    I have to end the call before other person ends it other wise I have to sit idle for at least a min to make other call...
    Can you please help me out in resolving this?
    has any body faced the similar situation.
    hoping to receive an answer.
    bye
    Praveena

    Please find my codes as below:
    On scree Painter at Flow Logic:
    process before output.
    module status_0100.
    process after input.
      module user_command at exit-command.
      chain. " every field here will keep editable
    field container.
    field shipment_no.
    field shipping_line.
    field bill_of_lad.
    field bl_date.
    field from_port.
    field to_port.
    field tanship_port.
    field vessel_no.
    field voyage_no.
    field container_wt.
    field container_vol.
    field date_of_shipment.
    field eda_port.
        module check_not_initial.
      endchain.
    MODULE user_command.
    module user_command_0100.
    In Program:
    data: wa type ZSHIPMENT01,
          pa type ZSHIPMENT02.
    data: ok_code type sy-ucomm,
          save_ok like ok_code.
    call screen 100.
    MODULE check_not_initial INPUT.
    if ZSHIPMENT01-CONTAINER IS INITIAL
    and ZSHIPMENT01-SHIPMENT_NO IS INITIAL
    and ZSHIPMENT01-SHIPPING_LINE IS INITIAL
    and ZSHIPMENT01-BILL_OF_LAD IS INITIAL
    and ZSHIPMENT01-BL_DATE IS INITIAL
    and ZSHIPMENT01-FROM_PORT IS INITIAL
    and ZSHIPMENT01-TO_PORT IS INITIAL
    and ZSHIPMENT01-TANSHIP_PORT IS INITIAL
    and ZSHIPMENT01-VESSEL_NO IS INITIAL
    and ZSHIPMENT01-VOYAGE_NO IS INITIAL
    and ZSHIPMENT01-CONTAINER_WT IS INITIAL
    and ZSHIPMENT01-CONTAINER_VOL IS INITIAL
    and ZSHIPMENT01-DATE_OF_SHIPMENT IS INITIAL
    and ZSHIPMENT01-EDA_PORT IS INITIAL.
        MESSAGE 'Please complete all entries.' TYPE 'E'.
      ENDIF.
    ENDMODULE.                 " CHECK_NOT_INITIAL  INPUT
    MODULE user_command INPUT.
      CASE ok_code.
        WHEN 'EXIT'. " defined as exit-command
          LEAVE PROGRAM.
        WHEN 'BACK'. " defined as exit-command
          LEAVE TO SCREEN 0.
        WHEN 'CONTINUE'.
          CALL SELECTION-SCREEN 50.
      ENDCASE.
    ENDMODULE.                 " USER_COMMAND  INPUT
    with thanks,
    DSC

  • Web Dynpro ABAP calling another ABAP program

    I have a question and just want to know if it's possible or not.
    Is it possible to write a Web Dynpro ABAP program that calls another ABAP program which happens to be an ALV report?
    Rather than re-write the ABAP ALV report, I was wondering if it's possible to call the ABAP ALV report within a Web Dynpro ABAP program and display the results within the Web Dynpro program.
    If it's not possible, then I assume it would be better to re-write the code from the ABAP ALV report in the Web Dynpro ABAP program.
    Thanks
    John

    The ALV report in your classic program is coded to be displayed in the GUI only.
    Your best bet would be to create a Function Module or Method that will return the data to be used in your ALV.  Simply call the Function/Method from your Web Dynpro and then bind the table to the DATA context node of the ALV INTERFACE CONTROLLER.

  • Calling another application from a java program

    Hi, Java ppl.
    I wanted to know how can I call another program say a help application or an exe from a java program. anyone with any advice or a piece of code would help.
    Thanks
    Pradeep

    I had the same situation and I tried the code that you sugested and it works. I was wondering, what am I expecting in the while loop that appears after the int inp; statement? Is some data going to be displayed on the screen? How essential is to have that while loop after the calling the exec() method?
    Sorry for the amount of questions, I never tried this before.
    Best regards,
    Luis E.

  • How to call another program as root in servlet

    In my servlet, I want to call another background programs (writeen in c) to do some tasks and gather the output of them as the output of my servlet. Is there any way to do so like Suexec in apache.
    Thanks

    sorry I forgot mention that the c program required the caller had root privilege.This is the problem I facing now.
    Thanks

  • Calling another program

    Is it possible to call another program (vlc media player in my case) in a VI???I dont want to use the Active X control for playin videos as it does not have much playback functions...

    Use the System exec.vi to launch any executable from LabVIEW in your case VLC player.  Provide the required inputs path, command line args so that you can obtain the desired functionality.
    With regards,
    JK
    (Certified LabVIEW Developer)
    Give Kudos for Good Answers, and Mark it a solution if your problem is solved.

  • Calling another program from the current program

    Hi all,
    In our requirement we are calling another program from our current program .
    In the current program( from which we are calling ) we are giving file name in the selection screen
    and when we run the current program we are successfully going to other program but our main requirement is to higlight the file name which we had given earlier .
    Note :  The called program doesnt have any selection screen.

    HI
    use EXPORT and IMPORT key words for passing data from one program to another program.
    as the called program is available in the same session you can use above key words which means you are accessing ABAP MEMORY.
    You can also use SET and GET key words which means SAP memory
    take F1 help there are examples tooo and detailes explanation abou the same
    Regards
    Ramchander Rao.K
    Edited by: Ramchander Krishnamraju on Dec 24, 2008 7:05 AM

  • Calling another program with in a program

    Hi experts,
            i want to call a program (second) from the first program. The problem is that the first program is called during the update task. so i think we cant use the submit statement.
    Thnak you in advance.
    Arul
    Edited by: arul m on May 6, 2009 12:36 PM

    Hello,
    Try this FM
    TH_IN_UPDATE_TASK
    check this
    http://help.sap.com/saphelp_nw04/helpdata/EN/fa/f23c15330411d5992100508b6b8b11/content.htm

  • How to execute the first program without using SUBMIT and RETURN

    Hi Experts,
    My requirement is , I need to select thet value from VA02 at runtime and need to pass that value to VF01 transaction and press save then it creates proforma document.The created document we can see in VA02 by clicking on document flow.
    My program is processed through OUTPUT TYPE.
    To get this functionality i written coding like this.
    1) i am selecting the value at runtime from VA02  using FORM ROUTINE.Now iam passing this selected value to VF01 for
    genarate proforma document using BDC.Here the problem is,first time when i am selecting the value form VA02 at runtime it is in open status,now my BDC code need to update the value in VA02 only.so locking problem occurres  the document is not getting updated.
    To overcome this problem i have done changes like this......
    2) i splited my program into two parts, that  is into two programs.
    a) In first program i am only selecting the value form VA02 at runtime using FORM ROUTINE and in this program i have written SUBMIT statement to call another program there my BDC  code will create documet and update in VA02,upto here everything is doing fine,
         But here again the problem is when i process OUTPUT type my program is triggering and giving correct result but the status is not changing form YELLOW to GREEN.Why means when SUBMIT statement trigger, control is going to second program and creating a new document,but not coming to first program so the status is not changing as the first prohram is still processing. .If i write RETURN along with SUBMIT the VA02 is in open STATUS only, till control comes to first program.so it will not uodate document in VA02.
    If i execute all line in my program status will automatically change from YELLOW to GREEN how to acheive this
    please suggest me the solution.

    I would do 2 things:
    1) be sure to do a COMMIT WORK AND WAIT
    2) refresh your display in calling program
    the point 2) can be done by submitting the program again (or the transaction) with the same parameters

  • Calling infotypes in module pool programming

    Hi experts,
    I want to guide end user to infotype 2003 using pa30 in dialog programming. I am able to take it to pa30 by 'call transaction' but i want it to directly go to 2003 in pa30 for the same employee.
    Need you help please.

    Hello Rekha
    you can use :
       set parameter  'PER'   <employee number>
       set parameter  'ITP'   '2003'
      set parameter  'SUB'   <Subtype>
    call transaction 'PA30' skip first screen.
    Reward points if helpful

  • RRI calling Web Browser instead ABAP program

    Hi All,
    I have created a RRI to call an ABAP program. However, when I try to call the ABAP program (via GOTO) it opens a web browser.
    If I execute the same query via RSRT, and call the ABAP program it works fine.
    I have also create another RRI to call another query from within BEx and it works fine.
    It only fails when calling ABAP program from BEx.
    I have read on to apply SAP NOTE 972514 - Set the ms/redirect_version parameter to value 1 and restart your ABAP Web Application.
    My ms/redirect is already = 1
    Any ideas?
    Thanks,
    Flavio

    I do have authorization. There is no error. It just open a internet explore (URL) instead of executing the ABAP program.
    Again, if I run the query via RSRT, it works just fine.
    Any ideas?
    cheers,
    Flavio

  • Start program BBP_LOCATIONS_GET_ALL first Error

    Hi, Friends,
    I am new to SRM, and facing some problem with shopping cart.
    First I have created a user with SU01, then given the role of  mySAP SRM Operational Purchaser.
    After that using Tcode users_gen and Create Users from Existing SU01 Users I have generated EBP user for that user.
      Then in the mySAP portal I cant use any steps including Shop, Check Status, Approval or anything else.
    When I clicked the settings then I got this massage :
    Note
    The following error text was processed in the system EBI : Start program BBP_LOCATIONS_GET_ALL first (see Note 563180 and long text)
    The error occurred on the application server dewall41_EBI_00 and in the work process 0 .
    The termination type was: ABORT_MESSAGE_STATE
    The ABAP call stack was:
    Form: CHECK_MIGRATION_RUN of program SAPLBBP_LOCATION
    Function: BBP_LOC_ATTR_V5502A_COMPLETE of program SAPLBBP_LOCATION
    Method: ATTRIBUTES_READ_LOCAL_5502 of program CL_BBP_ATTR_SCENARIO==========CP
    Method: ATTRIBUTES_READ_LOCAL of program CL_BBP_ATTR_SCENARIO==========CP
    Function: RHGA_READ_ATTRIBUTES_EXT of program SAPLHRBAS00GENATTR_RUNTIME
    Form: READ_ATTRIBUTES_EXT of program SAPLBBP_ATTR_PDORG
    Function: BBP_ATTR_MAINT of program SAPLBBP_ATTR_PDORG
    Form: ATTR_READ of program SAPLBBP_UM_UI
    Module: INIT_TRANSACTION of program SAPLBBP_UM_UI
    Please Help.
    Regards Amit.

    Hi Amit,
    Here are the details given in the OSS Note:
    Summary
    Symptom
    Locations as of EBP 4.0 - plant replication
    As of EBP 4.0, a business partner of type location must exist for every R/3 plant; for this reason, the plants must be replicated from all R/3 Backend systems known in the system.
    The system does not start an EBP application before the replication has not been executed successfully; the program terminate themselves and the system refers to this note with an error message.
    If you upgrade from BBP 2.0B or BBP 2.0C, you must first convert the old 'Shopping carts' so that the program plants described here can convert to locations. Use the BBP_TRANSFORM_SCS report for the conversion (see also note 481100).
    Process:
    The replication must be explicitly triggered by means of program BBP_LOCATIONS_GET_ALL.
    This program checks first whether the system in question is an upgrade system, and if necessary it checks whether XPRA BBP_ATTR_XPRA400 was terminated with errors (in this case, BBP_LOCATIONS_GET_ALL terminates and has to be restarted after a successful run of the XPRA).
    After the XPRA check, the system determines from table BBP_BACKEND_DEST all backend systems that can be accessed by RFC.
    Then the system reads all locations already existing in the EBP in order
    to convert any existing data in a legacy system
    to obtain comparison values to avoid duplicate records (identical data records with different partner numbers)
    Then the system imports the data for the plants from all back end systems determined before, compares them with the existing master records and either adds mapping entries or generates new business partners accordingly.
    In upgrade systems the following activities are also carried out:
    Conversion of the favorites (user-specific values for the last used business partners of the type location from table BBP_GRCPLANT_FAV)
    Conversion for user attributes WRK and REQUESTER (the business partner number is added to attribute WRK, the logical backend system is added to attribute REQUESTER)
    Conversion of the legacy documents (an entry with partner function 'Location' must be added to references 'Backend plant'; entries with business partner of type location as the ship-to party must be deleted and also an entry with partner function 'Location' must be added)
    If all subtasks could be executed without errors, the program finally sets the transaction authorization (that is, as of this time it is possible to start 'normal' EBP transactions as, for example, the shopping cart, again).
    The transaction authorization consists of a 'switch' in table T77S0 (GRPID = EBP and SEMID = LMIGR) which is delivered with value '0'.
    As long as this value is not set to 'X', all EBP transactions terminate themselves.
    Success/warning/error messages in program BBP_LOCATIONS_GET_ALL are stored in application log BBP_LOCATIONS_GET (Transaction SLG1).
    Setting the transaction authorization manually:
    The customer can decide to set the 'switch' in table T77S0 to 'X' and to allow the work start under the following circumstances:
    Only one error has occurred, this should be ignored
    One of several back ends broke down during an upgrade or during an installation, and a postponement of the system start cannot be allowed.
    Troubleshooting is not possible/required.
    This is only a local scenario (which should actually not exist because at least an FI R/3 Backend system should exist) so that a replication of plants is not possible.
    For this purpose, program BBP_LOCATION_MIGRATION_SET is availbale which sets required value 'X' in table T77S0 (if the program was started inadvertently, the original value can be restored using BBP_LOCATION_MIGRATION_RESET).
    If the replication from a backend system could not be executed it is possible to repeat this step at a later time via program BBP_LOCATIONS_GET_FROM_SYSTEM for exactly this R/3 system.
    If only single plants cannot be replicated (for example due to inadequately maintained data), they can be copied to the EBP after being revised with program BBP_LOCATIONS_GET_SELECTED (the program can also be used during normal operation to transfer new plants to locations).
    You can also create individual locations via the Web transaction 'Managing Business Partners' and assign them to an R/3 plant.
    Other terms
    Location, business partner, delivery point, plant, component, procurement, Business-to-Business, Ecommerce, e-commerce, Web, SAP Business-to-Business Procurement BBP, Business to Business, electronic commerce, e-business, Ebusiness, Internet, New Dimension, EBP, SAP Enterprise Buyer, Enterprise Buyer professional edition, SRM, Supplier Relationship Management
    Reason and Prerequisites
    IMPORTANT:
    This note does not apply to your R/3 system
    It only applies to EBP 4.0 and higher
    For upgrades from BBP2.0B and BBP2.0C, you must first execute the BBP_TRANSFORM_SCS report (Note 481100)
    Solution
    Proceed as described above.
    Header Data
    Release Status: Released for Customer
    Released on: 25.07.2005  06:48:45
    Master Language: German
    Priority: Recommendations/additional info
    Category: Upgrade information
    Primary Component: SRM-EBP-ADM-XBP External Business Partner
    Secondary Components: SRM-EBP-SHP Shopping Cart
    Affected Releases
    MDM 200 200 200  
    COM_CRMMDM 40 4.0 4.0  
    UIFRW 40 4.0 4.0  
    SRM_SERVER 500 500 500 X
    SRM_SERVER 550 550 550 X
    SRM_SERVER 600 600 600 X
    SRM_SERVER 700 700 700 X
    CGVMIC 10 100 100  
    BBPCRM 4.0 400 400 X
    Related Notes
    872533 - FAQ: Middleware
    737800 - Enhancements to upgrade on SAP CRM 4.0 SR1
    618400 - Support Package 01 for SRM 3.0
    481100 - EBP: Upgrade to Release 3.0A: Conversion of shopping carts
    Thanks,
    Pradeep

  • Incorrect call-up of the extraction program---error while extraction

    Hi All,
    We are loading the data first time(Full update) in BW Production we are getting the below error.
    Error message is as follows:
    Incorrect call-up of the extraction program     R3     8
    Errors in source system     RSM     340     
    Details of error are as follows:
    Requests (messages): Everything OK
    Extraction (messages): Errors occurred
    Error occurred in the data selection
    We request you help for correcting this error.
    Regards
    Deva

    Hi ,
    Here is little more info about error details we see in Status tab of monitor.
    Error message from the source system
    Diagnosis
    An error occurred in the source system.
    System Response
    Caller 09 contains an error message.
    Further analysis:
    The error occurred in Service API .
    Refer to the error message.
    Procedure
    How you remove the error depends on the error message.
    Note
    If the source system is a Client Workstation, then it is possible that the file that you wanted to load was being edited at the time of the data request. Make sure that the file is in the specified directory, that it is not being processed at the moment, and restart the
    regards
    Dev

Maybe you are looking for

  • 'name of file'.pages can't be opened

    I recently purchaced a new MacBook Pro (retina), before which I was using a standard MacBook (the white one from late 2009). I had updated all the software as much as I could only a couple of weeks prior to getting my new MacBook on the older one. I

  • Using The Summary Function in ADG

    Hello All, Please see my code below. Im using the advance data grid to create a summary row. The summary row currenty SUMs up the 'unqiuevists' and 'redemptions' columns and all is working well. What i want to do is then create a 3rd row called 'conv

  • Is my Mac good enough really?

    I think that I have the minimum Mac requirements for FCE HD. Does anyone out there have a mac similar to mine that can attest to FCE HD working properly or you being able to use all of its functions/ options? Thanks for the feedback (in advance), Jos

  • TS3989 Why is the date on my photo stream wrong

    My photos are gone in iphoto and the date at the top next to photo stream is wrong also?

  • IPhone freeze at Logo after Reseting.

    I decided to reset my iPhone after getting it back from my dad. I reseted all its contents VIA iPhone settings, but after its done reseting, it turns on but stops at the Apple Logo screen. After the first minute it shows the little circle loading ico