Start workflow with f. module to trigger event and how to pass data to BOR?

Hi,
I have a custom BOR object, with Event "Created". I have also an attribute in this BOR, just simple field Plant.
I have prepared a custom Workflow which is triggered when event Created of that custom BOR business object is raised.
To raise an event and to start a workflow I run f. module SAP_WAPI_CREATE_EVENT.
I have a problem to pass a Plant value to the Workflow container. In the PFTC_CHG for my Workflow I made the container
of BOR object, and the data binding &_EVT_OBJECT& => &MATREQ&  (symbol of my BOR).
Below both of EVTOBJECT and MATREQ I can see my field Plant.
Then I run f. module SAP_WAPI_CREATE_EVENT with tables parameter input_container.
I try to fill the data in many ways, but the started workflow does not have Plant filled.
I try to use '_EVT_OBJECT.WERKS' in field name for input_container parameters.
Business Object is passed to the Workflow container, but I do not get the fields
as attributes. Do I have to use the parameters for the event Created ?
Thank you in advance
Wojtek

Hello,
I've never used GUID as a key but I suppose the principles are the same - the object instance is equivalent to "something", say a widget.
This widget has attributes, e.g. the factory where it was created, the day it was created, its weight etc.
If you make a widget BOR object and you specify attributes then you're telling SAP how, given the key, it can deduce the value of the attributes. Widget 1234's weight can be looked up in table XXX by doing this select.
If you pass an object instance to a workflow then all you need to pass is the type of object and the key, the rest can be done by the workflow (or any other program). It can instantiate the object, and the attribute values are immediately available.
If you can instantiate the object in SWO1 and the attributes get values, then it should work in the workflow as well.
If not, please provide the code of the attribute or describe how it finds the attribute value.
regards
Rick Bakker
hanabi technology

Similar Messages

  • Start workflow with BAPI / RFC

    HI!
    I want to start a workflow in Business workflow by RFC. Are there any BAPI for this that i can use. ?

    Hey Dominik,
    Use following FM to start Workflow
      <b>SPH_SWW_WI_START_SIMPLE - RFC
      SWW_WI_START_SIMPLE - Normal FM</b>
    You can pass data by using parameter WI_CONTAINER in TABLES tab.
    Reward points if the answer is helpful.
    Thankx,
    Mukul

  • Starting workflow with HTTP-Post

    Hello,
    like I wrote in Starting workflow with HTTP-Post I have a problem with starting a workflow with a http-post:
    I have an installation of SAP ERP 2005 SR2 IDES on Win2003 SR2 SP2 and want to start a simple workflow with an external application. Therefor I created an elementary test-workflow and set the general task flag so everybody is allowed to start it. So far everything work fine as I start it manually.
    Now I want to start the workflow by an external application over a HTTP-Post as described in
    http://help.sap.com/saphelp_47x200/helpdata/EN/54/de9e3887d6174fe10000009b38f842/content.htm
    I configured the webserver (Customizing Web-Server) as follows:
    Service: WebFlow (Intranet)
    Address: http://192.168.0.216:8000/
    Path: SAP/BC/WORKFLOW_XML/?
    and sent a post via perl to http://192.168.0.216:8000/SAP/BC/WORKFLOW_XML/?protocol=01&localkey=WS99900004
    <?xml version="1.0" ?>
    <WfMessage Version="1.0" xmlns="http://www.wfmc.org/standards/doc/WF-XML">
    <WfMessageHeader>
    <Request ResponseRequired="No">
    <Key>http://192.168.0.216:8000/SAP/BC/WORKFLOW_XML/?protocol=01&localkey=WS99900004</Key>
    </WfMessageHeader>
    <WfMessageBody>
    <CreateProcessInstance.Request StartImmediately="true">
    <ObserverKey>http://192.168.0.224</ObserverKey>
    </CreateProcessInstance.Request>
    </WfMessageBody>
    </WfMessage>
    The Web-Server returns
    C:\FH\SAP\perl-scripte>perl http-post.pl
    HTTP/1.1 200 OK
    Server: SAP Web Application Server (1.0;700)
    Content-Length: 0
    Content-Type: text/plain
    Client-Date: Sun, 01 Jun 2008 11:00:24 GMT
    Client-Peer: 192.168.0.216:8000
    Client-Response-Num: 1
    but it seems that nothing happens.
    I also tried to post the XML via html-form-field with the same result.
    Did I forgot something essential?

    Hello Daniel
    It's 6 years after you posted your question, but I found your post very useful and thought it would be worth updating for future reference.
    I've just managed to trigger a workflow via http.
    URL :
    http://server.domain:8000/sap/bc/workflow_xml?sap-client=110
    Java :
    URL obj = new URL(url);
    URLConnection con = (URLConnection) obj.openConnection();
    String userpass = "username:password";
    String basicAuth = "Basic " + javax.xml.bind.DatatypeConverter.printBase64Binary(userpass.getBytes());
    con.setRequestProperty ("Authorization", basicAuth);
    con.setRequestProperty("Content-type", "text/xml");
    con.setDoOutput(true);
    DataOutputStream wr = new DataOutputStream(con.getOutputStream());
    wr.write( xml.getBytes("UTF-8") );
    wr.flush();
    wr.close();
    You can then read the response.
    I found that until I added the sap_client parameter I couldn't debug in CL_HTTP_WORKFLOW_XML->IF_HTTP_EXTENSION~HANDLE_REQUEST. Then I found that the content type has to be "text/xml".
    I set the xml variable (the data sent to ECC) to :
    <?xml version="1.0" ?>
    <WfMessage Version="SAP.1.0" xmlns="http://www.wfmc.org/standards/doc/WF-XML">
    <WfMessageHeader>
    <Request>
    <ResponseRequired>Yes</ResponseRequired>
    </Request>
    <Key>HTTP://server.domain:8000/SAP/BC/WORKFLOW_XML/?~localkey=WS90000074</Key>
    <Operation>CreateProcessInstance</Operation>
    </WfMessageHeader>
    <WfMessageBody>
    <CreateProcessInstance>
    <Key>HTTP://server.domain:8000/SAP/BC/WORKFLOW_XML/?~localkey=WS90000074</Key>
    <ContextData>
    <YOUR_CONTEXT_VARIABLE>x</YOUR_CONTEXT_VARIABLE>
    </ContextData>
    <StartImmediately>Yes</StartImmediately>
    </CreateProcessInstance>
    </WfMessageBody>
    </WfMessage>
    regards
    Steve

  • Is it possible to trigger FIPP event (and how?) when parking an FI document

    Hello
    I wander is it possible to trigger FIPP event (and how?) when parking an FI document with transaction fbv1(and not fv60)
    Thx in advance

    Hi,
    In Financial Accounting --> Accounts Receivable and Accounts payable >  Business Transaction> Incoming Invoices/Credit Memos  --> Make and check settings for Document Parking -->  Create Workflow Variant for Parking Documents (Click  this)
    There you have to assign your workflow.
    Regards,
    Surjith

  • My imac starts up with a white screen, gray apple and spinning gear and is frozen on that screen. What can I do?

    my imac starts up with a white screen, gray apple and spinning gear and is frozen on that screen. What can I do?

    Start your iMac with the original DVD that camera with the system.  Then open disk utility and repair your hard drive, also repair your permissions. 

  • Which apps come with a new Business Catalyst subscription and how do I get them?

    Which apps come with a new Business Catalyst subscription and how do I get them?

    When you break it down..
    - Ecommerce implementation that hooks into payment gateways.
    - PCI Level 1 compliance
    - Intergraated SSL so you do not need to pay for a certificate
    - SAAS - Updates and new features auto installed which you do not have to worry about
    - Support access to Adobe support staff most of the week
    - Server support, mainatance etc which you do not have to do or pay for
    - Blog, eCommerce etc all in one and not having to pay extra for along with the big one...
    - Marketing system in there and 10 email accounts as well in there.
    When you consider the stability and scalability and start adding those costs on other systems, to get to that level you would be paying as much if not more anyway and have your bits scattered across multiple systems trying to integrate them in.

  • HT4589 When using compressor voice is not sync with video. What causes this and how to fix it, please?

    When using compressor voice is not sync with video. What causes this and how to fix it, please?

    Although you say you have let the battery drain, was it for long enough? Since nothing else that you've tried so far has worked, I suggest that you leave the iPod unplugged for at least four days, preferably a week. That way, if something is stopping the iPod from turning the screen on, then whatever it is will drain the battrey. However, since the screen isn't on, that may take longer than if the screen was on.
    Then, after that time, plug the iPod into a power source and leave it alone for at least thirty minutes. Only after thirty minutes will it show any signs of life, but you should leave it until it is fully charged before trying to use it.
    If you get to this stage, the fact that the battery has drained will cause the iPod to reset when it springs back to life.
    Let us know how you get on.

  • How to create PDF with Form Builder (T-Code:SPF) and how to use it?

    How to create PDF with Form Builder (T-Code:SPF) and how to use it? Is there anyone can show me some doc. or PA material ? << removed >>  Thank you very much!!
    Edited by: Rob Burbank on Nov 11, 2010 1:04 PM

    PDF forms also known as Adobe From or Interactive Forms.
    Check this link -
    Interactive Forms
    REG:ADOBE FORM
    Adobe forms
    Regards,
    Amit

  • I have this question mark (?) in the upper left corner of my Finder windows. Anyone know what's up with that, what it might portend, and how to get rid of it?

    I have this question mark (?) in the upper left corner of my Finder windows. Anyone know what's up with that, what it might portend, and how to get rid of it?

    Are you sure you have a PowerMac? They can't run Mac OS 10.6.8. Maybe a Mac Pro instead?
    Can you post a screen shot of that portion of the screeen for us to review? Does the question mark replace the Apple that's at the left end of the menubar?

  • My Mac has Operative System MAC OS X Version 10.6.8,processor 2x2.66Ghz Dual core Intel Xeon. Is this compatible with Photoshop 5.5 or 5 and how can  I get it in Bogotá, Colombia or can I download it ?

    My Mac has Operative System MAC OS X Version 10.6.8,processor 2x2.66Ghz Dual core Intel Xeon. Is this compatible with Photoshop 5.5 or 5 and how can  I get it in Bogotá, Colombia or can I download it ?

    CS5 and CS5.5 are no longer sold. You can either buy CS6 or the subscription to CC. System requirements | Photoshop
    Benjamin

  • I downloaded the latest itunes and i recieved a message that the apple mobile device failed to start.  It asks me to verify that I have sufficient privileges to start system services.  What does this mean and how do I fix this so computer will sync iphone

    i downloaded the latest itunes and i recieved a message that the apple mobile device failed to start.  It asks me to verify that I have sufficient privileges to start system services.  What does this mean and how do I fix this so computer will sync iphone?

    You need to follow the instructions of tt2 in https://discussions.apple.com/thread/5822086 to straighten it out.

  • How to define custom event and how to trigger the defined event

    hi,guys
    hurry issue....................hope get help.
    I am using oracle weblogic 10gr3 portal.and we choiced java portlet.as of now,we got some question about custom Event.hope you can give some idea....
    thank you so much.
    question detail:
    1.for java portlet ,how to define custom event.
    2.how to trigger this event.
    3 about the data,may be sometime need to transit Biz data.
    auctully,I just want to implements between two portlets communicate.
    for example:
    existing portletA,portletB.
    portletA is a list,like:
    A AA <button>
    after I click this buttom,then portletB will be effect,it means they are interact with each other.
    does anybody hit this issue before,if you solved pls share me .
    thank you for you help....

    Hello,
    Please note that everything below applies to JSR168 portlets ONLY- JSR286 portlets and other portlet types handle events a little differently.
    From inside your JSR168 portlet you can send an event during processAction or when receiving another event by using the PortletBackingContext object, such as:
    import javax.portlet.ActionResponse;
    import javax.portlet.ActionRequest;
    import javax.servlet.http.HttpServletRequest;
    import com.bea.netuix.servlets.controls.portlet.backing.PortletBackingContext;
    public void processAction(ActionRequest actionRequest, ActionResponse actionResponse)
    HttpServletRequest httpRequest = (HttpServletRequest) actionRequest.getAttribute("javax.servlet.request");
    PortletBackingContext portletBackingContext = PortletBackingContext.getPortletBackingContext(httpRequest);
    portletBackingContext.fireCustomEvent("customEvent", "This is a custom event");
    To receive an event, in your .portlet file you just need to put in a "handleCustomEvent" tag specifying which method to call when the event is received, such as:
    <?xml version="1.0" encoding="UTF-8"?>
    <portal:root xmlns:netuix="http://www.bea.com/servers/netuix/xsd/controls/netuix/1.0.0"
    xmlns:portal="http://www.bea.com/servers/netuix/xsd/portal/support/1.0.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://www.bea.com/servers/netuix/xsd/portal/support/1.0.0 portal-support-1_0_0.xsd">
    <netuix:javaPortlet title="Listening Portlet" definitionLabel="yourPortletName">
    <netuix:handleCustomEvent event="customEvent" eventLabel="customEvent" filterable="true" description="custom event handler">
    <netuix:invokeJavaPortletMethod method="processCustomEvent"/>
    </netuix:handleCustomEvent>
    </netuix:javaPortlet>
    </portal:root>
    Then, in your receiving portlet the method "processCustomEvent" would receive the event, such as:
    public void processCustomEvent(ActionRequest actionRequest, ActionResponse actionResponse, Event event)
    The event payload can be any Serializable object you want, but for forward-compatibility with JSR286 it would be ideal if it had a valid JAXB binding.
    Kevin

  • Detect and save an event and the previous 60s data in a R32 file

    Hello
    I am a new user of Diadem.
    I perform long reliability test, and so the R32 file reach often 1 Giga byte (with a measure frequency of 500hz) when I stop manually the measure after the event . And after I only use the last 60s.
    I acquire a Voltage signal using a measurement instument connected to the Serial port, I save this signal in a document by using the document icon in the DAC (Circuit with packaged data)
    I have read the manuals but I don't know how to do the following thing:
    How to save only the last 60s in a buffer and write it into a file if they are followed by an event.
    The signal has normaly each 10s a 10v spike (During 7ms) but some time it remain constant near 4V during at least 5s and that is the event.
    How to do that in the DAC? Should I use a trigger with a timer condition, but I don't know how to do it with packaged data.
    Could you give me an example
    Thanks for your help
    Alfons

    Hello,
    I have
    created two Examples how to do this.
    The basic idea is to build packets with 60 seconds of data, find the event and
    save the last minute. One way to create the packet with 60 Seconds is the
    Offset Register. This block is also able to shift the signal by smaller steps.
    The signal
    is created with two generators and a manual switch to create the stop event. The
    blocks are running free, so you don’t have to wait a minute or more to test the
    behaviour. It is possible to simulate real timing in the generators if you like
    to see the real speed.
    In the
    simple example the Offset Register “1 Minute” is producing a packet with the
    last 30.000 values 10 times per second. This is shown in a scope. After this, a
    formula is looking for values between 2 and 6. All values in the packet are
    counted and if the number is above 2.500 (5 seconds) the block Relay gives
    this packet into the store and stop block. (Store is simulated with a scope to
    make testing easier.
    This
    example should do the job.
    I have also
    included an advanced example.
    In this
    example a formula is creating a second signal with trigger information. This
    signal has the same amount of values and can be used for more complex ways of
    triggering. In this example the formula is measuring the time when the signal
    is between 2 and 6. When the signal is not in this range the time is set to zero.
    The Multiplexer Block is used to build a loop to put the result of the formula
    back in to the formula. This allows the formula to ad 0.1 seconds to its own result
    from the loop before.
    The trigger
    signal is later used to store and stop the test. It is possible to create very
    flexible triggers, events and decisions during a process if this is needed.
    Of course,
    it is possible, that you have to change some of the blocks or add additional functions
    if the simple formulas are not able to separate the event from other changes in
    the signal.Ulrich Bierwisch
    Attachments:
    simple.DAC ‏37 KB
    advanced.DAC ‏46 KB

  • How to pass data at 'wait' event ?

    Hello,
    I created a workflow starting from a form: the user can chose a production order number.
    Inside the workflow there's a step (= wait ) and the system wait until an event (BUS2005-DELETE) is raising.
    My requirement is:
    When the event BUS2005-DELETE is raising I have to finish the workflow but only if the event is raising for the
    production order number entered from the user.
    So, my question is:
    How to pass the production order number at the WAIT event ??
    Tks.

    Hello Roberto Baldassarre  !
                   To instantiate your BOR, release it and do the event binding at workflow and also the binding at wait step perfectly.
    Regards,
    S.Suresh

  • I am having much trouble with the new reminders in IOS7 and how it interacts with Outlook Exchange. Many features lost in the new version.

    When I downloaded IOS7, I found that the reminders/task app and how it interacts with Outlook Exchange is much more difficult to use. Some of the issues that I am having are...
    1. Trying to edit my task on my phone is not possible, if the notes are lengthy. When you click on the text to edit data near the top, it will scroll to the bottom and not allow you to edit the text because you cant see it.
    2. Now all of my task are in one long list. I can not move from day to day like we could in previous version IOS6
    3. When I do edit a short task reminder and click done, it crashes and completly goes away. It does save the edit though
    4. You can only add task at the bottom of each days reminders. This is very inconvient and much more difficult than IOS6
    5. There is a major delay or latency when interacting inside of reminders in this version. Much more than IOS6. It is very unstable and quirky.
    I have never seen Apple take a step back with a product until now. I am a huge Apple fan and always will be, so I am hoping they make enhancements to fix these issue. It is a big time prodcutivity killer.
    Thanks for any and all help you can give.
    Troy Meachum

    Some power supplies or designed so that if there is a short or overload they shut them selfs off and some will not turn back on. Some have a relay that will click back on and work, some you have to  cycle the power switch. Those that won't come back on will have to be replaced. I'm not saying that yours is that type as I have no way of telling. But if you have a friend who will loan you a good power supply you might try it. As someone else said just turning off the power will not darn all the power from some motherboards. To test this turn off your power supply than turn on the computer with the start botton. Mine will flash the lights and fans will start to spin than die. So every time you turn off computer to work on it. After turning off PSU hit the start botton to drian any power left in it before working on it. Also do this after unplugging it just to make sure.

Maybe you are looking for

  • Can XI pick up a report sitting in database?

    Hi, We have a report thats been generated using a query in DB access. Requirement: To  mail that report to the receipents. Can we use XI to pick up that report and mail it as attachment to receivers?? The important thing is how to pick up that report

  • Upgrade Bug from 3.0.1 to 4.0.1 - syntax not accepted now

    Hi, I have just upgraded to Apex 4.0.1 (full installation from previous installed 3.0.1) in order to add the Ajax item functionality to my existing 3.0.1 app and getting the following really weird syntax error when I try to build an existing 'On Subm

  • How can I CACULATE the current X,Y coordinate?

    Hi Veterans, When I was using method Graphics.drawString(String str, int x, int y) to display the string on the specified (x, y), how can I calculate the current x at the end of the string when i finished, given the font size is available any help is

  • Wifi syncing not working

    My iPhone 4 has the latest version of iOS5, my 27" iMac has also been upgraded to the latest version of Lion.   The iMac is hardwired to my home network and the phone is connected to the same network via wifi and is connected to power.   I have check

  • How to get a Zen V Plus out of shuff

    I bought a Zen V Plus last night and i put in shuffle..now i want it out of shuffle and i don't know how. Please help