How to raise a Terminating Event for a Standard Task?

Hi Experts,
I have a standard task where I have defined the Terminating event to stop the workflow.
This Task/Workflow will be triggered by a batch program.
Also in a class method I am using function module SWE_EVENT_CREATE to raise a event which should complete the workflow.  But somehow the work items are still in In Process status.
May be I am passing wrong parameters OR using wrong FM to raise a terminating event.
Request you to help me on this.  Thanks in Advance.
Regards,
Sudhakar.

Hi Sudhakar,
Since there are entries in SWE3 which show link each time event is triggered. So I would suggest you will have to check the standard task you are using is working. So create a parallel branch with activity on one end and wait for event step on other. See if the the wait for event step works, when you create the event using create event. If it works then most likely your task binding has a problem. If not then event that is triggered does not getting picked by workflow. So based on the finding we can find a solution.
I notice that you are calling the event from an ABAP class, so in that case the code for calling event seems to be different. Check out the below SAP help documentation.
http://help.sap.com/saphelp_nw2004s/helpdata/en/a1/172437130e0d09e10000009b38f839/frameset.htm
Regards,
Kartik N.
Edited by: KARTIK Nayak on Dec 12, 2008 8:25 PM

Similar Messages

  • How to raise on click event for Single Markable cell in WD Table

    Hi All,
        I want to raise an event when a cell is clicked on Single Markable Cell and get the row and column of that cell.
    I have tried all the events of the table and also On Enter event of input Field.
    But I am not able to trigger on click event .
    Please help me out. Points will be rewarded.
    Thanks,
    Anil

    Hi Anil,
            If the cell editor is a link to action then it triggers the ON CLICK event , Write the following code into
           the ON CLICK event handler to get the selected Row and Column ID.
          Event Properties is a node with two attributes Name and Value of type string.
    data: lr_node type ref to if_wd_context_node,
    lt_event_properties type wd_this->elements_event_properties,
    ls_event_properties type wd_this->element_event_properties.
    field-symbols: <l_value> type any.
    * fill internal table
    ls_event_properties-name = 'COLUMN_ID'.
    ls_event_properties-value = r_param->column.
    append ls_event_properties to lt_event_properties.
    ls_event_properties-name = 'INDEX'.
    ls_event_properties-value = r_param->index.
    append ls_event_properties to lt_event_properties.
    ls_event_properties-name = 'ATTRIBUTE'.
    ls_event_properties-value = r_param->attribute.
    append ls_event_properties to lt_event_properties.
    assign r_param->value->* to <l_value>.
    ls_event_properties-name = 'VALUE'.
    ls_event_properties-value = <l_value>.
    append ls_event_properties to lt_event_properties.

  • Terminating Event for BUS2017 Custom Method

    Dear Experts,
    I have an issue with the Terminating Event of the Workflow for BO : BUS2017. The event is getting triggered but receiver is not being picked.
    I have created two events GR_103 and POST_105 in the Custom BO ZBUS2017 by delegating it to BUS2017. GR_103 is the triggering event for my workflow which I have triggered in the POST_DOCUMENT Method of the Implmentation for BADI : MB_MIGO_BADI.
    GR_103 is triggered while doing MIGO (Goods Receipt) for Movement Type 103. My Workflow is triggered perfectly and then I have used a Dialog Asynchronous Task in which I have called the MIGO Transaction for Releasing the GR Blokced Stock using the Movement Type 105. I have created a Custom Method POST in the BO ZBUS2017 and I have used the FM: MIGO_DIALOG to call the MIGO. I am trying to raise the POST_105 event in the Method MB_DOCUMENT_BEFORE_UPDATE of the Interface IF_EX_MB_DOCUMENT_BADI.  I have defined the Terminating Event for the asynchronous Task as POST_105.
    Now the event POST_105 is triggered, but SWEL says 'No receiver entered'. Even the SWEINST shows the object data as the current Work Item along with Object Key, but still receiver not picked. When I try to trigger the same event in a test report by using call transaction, then the event triggers and work item gets completed without any issues.
    Please advise.
    Below is my terminating event code.
      READ TABLE xmseg INTO wa_mseg INDEX 1.
      CONCATENATE wa_mseg-mblnr wa_mseg-mjahr INTO l_objkey.
      IF wa_mseg-bwart = '105' .
        CALL FUNCTION 'SWE_EVENT_CREATE'
          EXPORTING
            objtype           = 'BUS2017'
            objkey            = l_objkey
            event             = 'POST_105'
          EXCEPTIONS
            objtype_not_found = 1
            OTHERS            = 2.
      ENDIF.
    Regards,
    Raju.

    Have a COMMIT WORK after the function call. (At least test it - I am not sure if it will have some effects in your BADI - at least you will know whether the issue is about missing commit).
    And please use SAP_WAPI_CREATE_EVENT instead of the old function you are using.
    Also, make sure that the events will look exactly the same in event monitor SWEL when triggered from your code and when using test tool. Maybe there is some minor difference/mistake (object key, etc.) that you haven't noticed.
    Regards,
    Karri
    Edited by: Karri Kemppi on Feb 7, 2012 8:14 AM

  • I movie 11: how do i find an event for a particular clip in my project

    I movie 11: how do i find an event for a particular clip in my project

    Thanks so much for your response.  I tried that though and it did not work... any other suggestions?

  • How to find the BTE event for FBCJ transaction code

    Hi All,
            i need to find the BTE event for Finance related transaction codes.i checked in the SWEL transaction code, didnt find any event triggered and the standard BADI doesnt suite my requirement.The transaction code  which i tried is FBCJ.can anyone help me how to find the BTE event for the above mentioned transaction.
    Thanks in Advance,
    lokesh kumar.K

    Hello Lokesh,
    The following is one of the process of finding a BTE and implementing it.
    (1)Goto transction FIBF .Execute it with Attribute type = 'A'. Then in the menubar Environment->Info System (P/S )
           Go through the list of BTE's available with the description available beside.
    (2)Select the BTE you want to implement.
    (3)Press button Sample function module
    (4)This brings you to SE37 - Copy the sample function module to a Z-function module (First create a new function group for the function module) . Note: The name of the Z-functionmodule is not important
    (5)Edit the code in the new function module
    (6)Go back to transaction FIBF - Menu Settings->Products -> Of a customer and create a new product whicj identifies the new product . Remember to mark the Active field.
    (7)Go back to FIBF menu Settings->P/S function modules->of a customer - Create an entry that links the BTE and Product with the new function module
    Hope this will help.
    Regards,
    Samson

  • How much is early termination fee for basic phone, my contract is done 1/18/15?

    How much is early termination fee for basic phone, my contract is done 1/18/15?

    There is a $10 discount available for basic phones to knock that cost down. You can visit your local store, add the discount online, or call customer care @ 800-922-0204. Hope this helps.

  • How to detect window close event and do some task before exiting

    Hi 
    Anyone knows how to detect window close event and do some task before exiting ?
    Sridhar
    Solved!
    Go to Solution.
    Attachments:
    window close event.JPG ‏34 KB

    Yes .You can discard the panel close event by passing "TRUE" boolean value to the "discard ?" terminal which is lied in the right side of that panel close(filter) event.& It will work in executables.  See attached picture.
    Attachments:
    Panel Close.JPG ‏12 KB

  • How to create a custom task in SRM for the standard task

    Hi Gurus,
    How to create a custom task in SRM for the standard task  eg: TS10407929
    regards,
    George.

    from PFTC itself. Same.

  • How can i add one field in the container for the standard task-90310004?

    Hi,
    Please let me know thw steps to add one field in the container for the standard task-90310004.
    Usefull suggestions will be rewarded.
    Regards,
    Neslin.

    <b>Hi,
    Containers are used for holding Application data for Workflow purposes.
    Event container
    Task container
    Workflow container
    Role container
    Binding is the linking of data from one container to the other for making data available all across the workflow.
    But you can get values from one container to another container like this
    Container(Con)
    1. WF Con to Role, Wf con to task con, Wf con to event
    and
    2. Event con to wf con, task con to wof con
    and
    3. Method con to task con
    and
    4. Task con to method con
    So, we don't have direct possible binding from task con to task con.
    Thanks and Regards,
    Prabhakar Dharmala</b>
    Message was edited by:
            Prabhakar Dharmala
        But you can do pass values from first task con to wf con and again from wf con to another task con

  • How can I register a Event for TAB???

    Hi,
    my problem is, that i search for an solution to register an Event for Tabulator (Tab Key).
    If i klick to tab, than it must be trigger the event!!
    I have found in forum following:
    http://webcache.googleusercontent.com/search?q=cache:fk2pfn0bhiwj:www.sdn.sap.com/irj/scn/thread%3fmessageid%3d1078796eventtabulatoralvgrid&cd=50&hl=de&ct=clnk&gl=de
    How must I register my TAB Event ????
    Please give an example!
    Thanks in forwards.
    Ersin

    Thanks for Help:-)

  • ALV Grid editable - How to raise the data_changed event from outside object

    Hi,
    i'd like to like to raise the data_changed event from outside the ALV-Grid object in order to display errors to the user.
    For example a new row was inserted within the program. The user has only to complete the missing informations. Before saving the transactions the program has to execute some semantic checks. The errors of this check process should be shown to the user by creating an instance of the cl_alv_changed_data_portocol object.
    Thanks.
    Regards

    You don't need to raise the data_changed event to perform the edits or to issue messages using cl_alv_changed_data_protocol.
    The following assumes you have an ALV grid object g_alv based on the CL_GUI_ALV_GRID class.
    You can mark the inserted records upon insertion as selected using the set_selected_rows method, and then retrieve these rows later using get_selected_rows and perform necessary edits.
    Save the row number of each inserted row into a table of the appropriate type (see the method definition for this):
    DATA: t_index_rows    TYPE  lvc_t_row.
    DATA: s_row_no        TYPE  lvc_s_roid.
    DATA: t_row_no        TYPE  lvc_t_roid.
    Load entries into t_row_no after each insert.  Capture the row number and save in the table t_row_no.
    e.g.
    PERFORM insert_row USING s_row_no-row_id.
    APPEND s_row_no TO t_row_no.
    FORM insert_row would have whatever code you are using to insert the row.  Save the row id into s_row_no-row_id (which is an INT4).
    When done with all inserts do the following
      IF t_row_no[] IS NOT INITIAL.
        CALL METHOD g_alv->set_selected_rows
          EXPORTING
            it_index_rows            = t_index_rows
            it_row_no                = t_row_no
            is_keep_other_selections = 'X'.
      ENDIF.
    Then, if SAVE is pressed without the data_changed event having been raised (such as if the user just pressed SAVE without changing anything), use method get_selected_rows to retrieve the rows that were inserted and perform the necessary edits.
      DATA: l_t_rows    TYPE lvc_t_row.              " ALV control: Table rows
      CALL METHOD g_alv->get_selected_rows
        IMPORTING
          et_index_rows = l_t_rows.
    Loop through l_t_rows and use the row as an index into the grid, perform the necessary edits, just as you would if the data_changed event had been raised.
    If any edits fail, then send messages to the user, abort the save, and re-display the grid.
    Remember to refresh the t_row_no and t_index_rows tables if you load a new data set.
    You can also use a similar technique with the data_changed event to mark each changed row as selected by saving the row ids, and then you only have to update the changed rows on SAVE, which can minimize database I/O.
    Good luck.
    Brian

  • How to raise a component event via script

    Hi all i have a DateField in wich a set the text with the text property, and i would like to raise the CalendarLayoutChangeEvent event programmatically via the scripts code.
    How can i do that?
    Thanks.

    Ok, i did it, but this is my code:
    dispatchEvent(new Event(CalendarLayoutChangeEvent.CHANGE));
    i tried also with:
    data.dispatchEvent(new Event(CalendarLayoutChangeEvent.CHANGE));
    where data is my DateField component, but it did not work.
    Can you help me to find the right code?.
    Thanks.
    Skylander.

  • How to raise Remote System Event

    Hi,
    I need to load data from a remote DB system (Not SAP system) when data is created or modified.  I setup DB Connect to load the remote data with an event triggered InfoPackage.  How can remote system trigger the local event?
    Thanks,
    Frank

    Frank, there should be a command on the server that your R/3 or BW system resides on called <b>sapevt</b>.  This command sits outside the SAP system and its sole purpose is to allow you to raise an SAP event from outside the SAP system.
    check out the following link:
    http://help.sap.com/saphelp_erp2004/helpdata/en/fa/096e6b543b11d1898e0000e8322d00/frameset.htm
    Regards,
    George

  • How to set fire action event for particular rows in a table

    HI All,
    I have a requirement in which I want to set fire action event for particular rows in a table based on some condition.
    The table has columns like fullname,employee id etc.
    So i want to set fire action event for particulars rows only which will saisfy some condition.

    Atanu,
    Your approach(setting fire action for few rows) seems not possible. Better to go ahead with workaround.
    Do you want this functionality in processRequest(while page loading) or processFromRequest(on some event) method ? Give more explanation regd. your requirement ?
    In either case loop through the rows and when your condition is met write the action to be performed in controller.
    Regards,
    Anand

  • How can I register an EVENT for ALV-GRID?????

    Hi,
    i have create Events for my ALV-Grid Table (cl_gui_alv_grid).
    But there is one Problem!!!!
    Which Event must i create, if users write something in the ALV row and press to key "enter" ???
    With kind regards
    Ersin

    Did you set the handler for one of forementioned events? If no, please suplement your code with the following
    "create handler class
    CLASS lcl_gui_alv_event_receiver DEFINITION.
      PUBLIC SECTION.
        METHODS:
    "        Controlling data changes when ALV Grid is editable
              handle_data_changed FOR EVENT data_changed OF cl_gui_alv_grid
                                  IMPORTING er_data_changed e_onf4 e_onf4_before e_onf4_after,
    "       To be triggered after data changing is finished
              handle_data_changed_finished FOR EVENT data_changed_finished OF cl_gui_alv_grid
                                           IMPORTING e_modified ,
    ENDCLASS.                  
    "implement you handler methods
    CLASS lcl_gui_alv_event_receiver IMPLEMENTATION.
      METHOD handle_data_changed .
        MESSAGE 'Data changed' TYPE 'I'.
      ENDMETHOD.
      METHOD handle_data_changed_finished .
         MESSAGE 'Data changed finished' TYPE 'I'.
      ENDMETHOD .
    ENDCLASS.
    data:  g_alv_event_ref TYPE REF TO lcl_gui_alv_event_receiver.
    CREATE OBJECT g_alv_event_ref.
    "set handlers for these events
    SET HANDLER:
      g_alv_event_ref->handle_data_changed FOR g_alv_grid_ref,
      g_alv_event_ref->handle_data_changed_finished FOR g_alv_grid_ref,
    "register the events after pressing enter
    CALL METHOD g_alv_grid_ref->register_edit_event
          EXPORTING
            i_event_id = cl_gui_alv_grid=>mc_evt_enter.
    Regards
    Marcin

Maybe you are looking for