Fire EPCF event with WD ABAP in EP

In EP 7 I want to fire an EPCF event. I use the code below. A similar example from WD java works, but here I never receive the event. The Javascript part is right since it works together with an HTML and WD Java iView. Only the WD example is not working. Any hints?
ABAP ("triggered by a button")
DATA:
  L_API_COMPONENT TYPE REF TO IF_WD_COMPONENT,
  L_PORTAL_MANAGER TYPE REF TO IF_WD_PORTAL_INTEGRATION.
L_API_COMPONENT = WD_COMP_CONTROLLER->WD_GET_API( ).
L_PORTAL_MANAGER = L_API_COMPONENT->GET_PORTAL_MANAGER( ).
L_PORTAL_MANAGER->FIRE( PORTAL_EVENT_NAMESPACE = 'urn:xxDemo' PORTAL_EVENT_NAME = 'simpleevent' PORTAL_EVENT_PARAMETER = 'HelloFromABAP' ).
JavaScript:
EPCM.relaxDocumentDomain();
EPCM.subscribeEvent('urn:xxDemo', 'simpleevent', handle_simpleevent_Event);

Good hint, it was not the domain, but the protocol (http/https).
One iView was on https while the other one was setup for http.
However, now the question is: Can I setup EPCF somehow to work with mixed http/https IViews. In my HTML page I can use EPCMProxy, but I have no idea how to change this on a WD ABAP.
Regards

Similar Messages

  • How to fire an event  with a non-AWT/Swing class?

    Hi, Everybody,
    I have an object that parse an XML file. When I meet an element with the value "true", I would like to fire an event, for instance a KeyEvent, just like a special key is pressed.
    Could you provide me an example?
    Thanks.
    Youbin

    use the firepropertychange methods as you do in beans.
    iam giving an eg.
    class abc
        MyListener lis;
        addMyListener(MyListener lis)
            this.lis = lis;
        abc()
            lis.fireEvent(new MyEvent("Class Instantiated"));
    class MyEvent extends EventObject
        String e;
        MyEvent(Object src)
            super(src);
        MyEvent(String e)
            this.e = e;
    interface MyListener
        public void fireMyEvent(MyEvent e);
    }You can use this methedology.Any class implementing MyListener will the be notified of the event and your class abc can now generate events wherever it wants just like i fired an event during initialization.
    you can also use observable/observer to achieve the same.

  • How can I fire an event case on the value change of an indicator, or a network variable?

    Hi!  I have an event structure setup to look for a value change of an indicator on the front panel.  The indicator is updated by the value of a boolean network-published shared variable through a seperate parallel loop that is polling all of the network-published shared variables.  The event, however, does not fire when the indicator changes value.  I have switched the indicator to a control and tested it with user interaction and that works just fine.
    I want to use the event structure space for my code exectution because it seems logical that that is where it would go, and it will help keep my block diagram tity.  The code is also something I would like executed with the front pannel temperarily disabled.  I would rather not have the code in my network-variable polling loop because again the tity issue.   I would also rather not use a notification VI wired to an independent loop for this particular code.
    Is there a way to have an event structure fire an event with the value change of an indicator, or a network variable directly?
    Thanks for your input.
    LV 8.5
    -Nic

    Thanks for the reply.
    I went about things a little differently, but got them to work so..... .  It really was not my desire to have a boolean indicator on the front panel.  As previously stated, my ultimate goal was to have an event fire on the change of a network variable, which I had to poll for anyway but that is tucked away in a section where I am handling all my network variables.  I ended up using that Create User Event, Register User Event, and Generate User Event SubVIs to handle the task.
    I've read the help for all of those SubVI's and it is not entirely clear to me if the event fires every time the "Generate User Event" receives some inputs, or if it only fires when the value changes.  I could do a test to find out.  It wouldn't be too difficult to add a shift register or a feedback node and place the Generate User Event in a case structure so that it is only fired when the input changes state.

  • Fire A Portal Event With Source Id

    Hi All,
    I have this requirement where I need to fire an event from a Web Dynpro iView and a delivered iView (MSS Team Viewer) will receive it.  The problem is the receiving iView (Team Viewer) need the source id parameter which is available in EPCF raiseEvent as an optional fourth parameter but the method WDPortalEventing.fire() method does not have it.  Is there a workaround for populating this parameter?  I wonder why it is omitted in the Portal Eventing API.
    Thanks in advance.
    Erwin

    Hi Julia,
    Yes, you can have 2 users with same uid in 2 different org but then, you must use 2 different authentication module and then your login url must be something like : .../UI/Login?org=yourOrgName
    And then, this organization must have a Auth module.
    Now, for the users, it's better to propose only the good login url.
    ie, we have 5 differents login url based on 5 differents org. I'd change the login provider to alow the user to change its own organisation (with a list box). I've change the file under LoginProvider directory... (JES 2005Q4, Portal 6 : /etc/opt/SUNWps/desktop/default/LoginProvider/display.template
    I think, in Portal 7, you have a jsp provider. Easier ;-)
    a+
    Philippe

  • Fire events with run-time menu

    Hi,
    I developed an application based on an event structure. Almost all the events are fired when their corresponding controls are modified. I’d like now to alternatively fire an event by selecting an item in the run-time menu. 
    In the ‘Menu Selection with Events.vi’ example the selection of any item in the run-time menu fires the event 0 (specifier menu selection (user)). Inside that event 0 according to the item a function is executed.
    Is is possible to point out to another event instead? Or is possible to add the selection a menu item (or sub menu item) to fire an event that is usually fired when a the value of a control changes?
    I enclose a VI and its .rtm file (LabVIEW 8.0)
    Thanks,
    Charly
    It's always sunny in California! Certified LabVIEW Associate Developer!
    Attachments:
    MenuEventStructure Folder1.zip ‏19 KB

    This is to shine light on Wiebe response, here how you can do it:
    yet, this mode of operation works with switching booleans, not with latching (you cannot set the value of a latch indefinitely). therefore you will also need to implement a prgramatic latching solution (e.g. after 200ms return value to false).
    a more involved, but better solution would be to register the events.
    Message Edited by Gabi1 on 10-08-2007 02:31 PM
    ... And here's where I keep assorted lengths of wires...
    Attachments:
    MenuEventStructure.png ‏13 KB

  • How to fire event with parameter?

    Hi folks,
    does anyone know how to use the event parameter functionality?
    My idea is to fire an event within the richisland and pass a parameter value. As I recognized the function
    var myParameter:Number = new Number();
    FlashIsland.fireEvent(this,"myEvent",myParameter);
    On WD side in ROOTUIELEMENTCONTAINER I created a child element of type GACEvent, named myEvent. This event has a GACEventParameter named myParameter.
    But running the app I am getting a dump:
    WebDynpro Exception: ERROR: GAC_EVENT_PARAMETER 'myParameter' missing (GAC_EVENT='myEvent')
    Any idea of how to fix this?

    Hi,
    I solved it now. The correct syntax is:
    FlashIsland.fireEvent(this, 'myEvent', {myParameter:myValue});
    Hope it helps you too.
    Greets

  • Fire another event from with an event

    How best to fire an event (say a boolean value change) from within another different event (say a second boolean value change) ? I've tried having the second event assign a value to the first boolean's Value Signaling property. This does fire the first event, but its code does not seem to be executed until the end of the second event. Both events have the event's Time property wired to front panel indicators to show when they fire. The first event also has a GetTickCount wired to a front panel indicator. The second event has a sequence structure which first changes the first boolean's Value Signaling property, then Waits 1000 msec, then performs GetTickCount. I would expect the two event's GetTickCount values to be differen
    t by 1000 msec but instead they are the same. The Time value of the first event is 1000 msec less however. Why does the first event's GetTickCount not get executed until after the delay in the event which fired it ? The same behavior occurs if CreateUserEvent and GenerateUserEvent are used in a similar manner.
    Attachments:
    Fire_Event_from_Another_Event.vi ‏76 KB

    The time given by the event structure is the time the event actually was generated.
    So when you generate a user event and then wait a second until you allow that user event to actually be handled the time of the user event is not one second after. You do not change the time the event fired, you just delay when it is handled.
    The same goes for the event fired using the value property.
    MTO

  • BSP: How copy received portal event string to ABAP-Page-Attribute variable?

    Hi,
    I am able to receive and display portal events (EPCF API) with the following code:
    <SCRIPT src="epcfproxy.js"></SCRIPT>
    <script language="javascript">
    if(window.document.domain == window.location.hostname){
    document.domain = document.domain.substring(document.domain.indexOf('.')+1);
        EPCMPROXY.subscribeEvent("urn:com.sap:BWEvents","BWiViewevent", window, "myreceiveEvent");
    function myreceiveEvent( eventObj ) {
       alert("event received:" + eventObj.dataObject );
    But now the received data is only stored in Javascript-"variables".
    How can I copy the received string to ABAP variables? These variables will be declared as Page Attribute (e.g. rec_event_data  TYPE STRING)
    Is my Javascript-solution a good way to handle portal events or are there better solutions?
    Thanks a lot.
    Regards,
    Henning

    Hi,
    yes I was able to do it.
    The code should be something like this. I can not test it at the moment.
    function myreceiveEvent( eventObj )
            document.form1.rec_event.value = eventObj.dataObject;
            document.form1.submit();
    <htmlb:form id="form1">
          <input type="hidden" name="rec_event" value="">
    </htmlb:form>
    Event Handler: OnInputProcessing
    rec_event_data = request->get_form_field('rec_event').
    Regrads,
    Henning

  • 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

  • Terminating event 'Created' in ABAP OO context

    Hi,
    I need a little help here. A lot of times I have used terminating event ‘Created’ for different BOR types – and asynchronous tasks where users are asked to create an object using call transaction from a work item.
    Now I am struggling with the same in ABAP OO and have an issue:
    The goal is to have a terminating event raised on a custom class  - and received by a work item if a customer is fully created, that is the general part, the company code part and the sales area part.
    Raising the event is working great. I have put in a class in trx. SWEC together with a function module which set the class as object type if the condition is fulfilled.
    Then in trx. SWED I have entered another function module to set the key for class together with object_por-catid = ‘CL’.
    Then when a customer master record is created I can see in the event trace that the event is raised with the correct key.
    No I want to receive the new object into my asynchronous dialog task. I define the event as terminating event – and in the code call transaction XD01.
    When the work item is created I find a waiting event linkage in trx. SWE3 – of cause without key; this is unknown until after creating.
    But after executing the workitem and raising the event the workitem does not receive the event and is therefore not completed.
    Is this approach not possible in ABAP OO – or do I miss something in the class definition / coding?
    The event is defined as public instance – I have not coded any event handler method.
    Thanks,
    Claus.

    Hello Claus,
    Interesting question, unfortunately not with a simple answer.
    The issue is that you are waiting for an instance event without a key. Your object raises an event with a key => No match.
    If you raise the created event without a key, you won't be able to match up two near-simultaneous creations with their corresponding work items. Same thing if you wait for a static event.
    So how does SAP do it with BOR events? By breaking the rules of course!
    They do some hidden trickery to bypass this problem by doing an 'Export to Memory' of the work item ID, and the CREATED event raising code bypasses the usual event linking mechanisms and looks for it's creator by retrieving the memory variable. I don't have the exact spots of code in my head, but a bit of debugging should find it.
    So what can you do? Given that you have full control of the class you could do something similar and maybe also create some kind of temporary key consisting of the Work Item ID and raise an event with that, or you could maybe skip the transaction concept completely and run the create GUI entirely within your WF step - maybe a custom screen gathering the initial data and then create the object via BAPI. Time to get creative!
    Hope that helps,
    Mike
    Edit: Or you could do the quick and dirty solution and just use the BOR events for the step and instantiate the class during the binding back to WF...

  • MDM Log / EPCF Eventing in Result and Item Details Iview

    Hi,
    I have EP7 with SP15 and MDM 6.0, recently upgraded. Before upgrade we have an application which uses the MDM iviews and maps the fields of one table to other and displays in some other iview.
    The application was working fine before upgrade of MDM. But after upgrade, the mapping seems not working.
    My scenario is as : Using MDM Search iview, I search records from MDM repository, Main Table. This result is displayed in MDM Result iview. From this result iview, I select a record. From this selected record, a field is mapped to the other table. The mapped record, then, is displayed in MDM Details Iview.
    After MDM upgrade, whenever we select a record from the result of table 1,the mapped iview throws erros :
    Error occurred: Error performing search. com.sap.mdm.internal.protocol.manual.ServerException: Illegal value for parameter, com.sap.mdm.internal.protocol.manual.ServerException: Illegal value for parameter (see log for details)
    when serached log : Key is not found in table:<Table1>-KeyMappings it may have been deleted or renamed, please use editor to fix the problem##
    We have used EPCF eventing for MDM iviews.
    I have written some code to check the values passed from Result Iview and seen that the values are being passed correctly...Now think, i should also have a check in MDM how the values are recieved and mapped...
    Any idea how I can use MDM log service to do this? Or any idea how I can enable MDM log to monitor what comes in and what goes out?
    has anyone out there faced same issue ?
    Please let me know your views.
    Regards,
    Abhijeet

    Solved at my own. The MDM SP6 needs the subtable key field to be TEXT type.

  • Event triggering by abap class & ISR

    hi gurus
    1 ) can i able to see the event triggering by abap class in SWEL ?  ,
    2) in custom  ISR scenario , new form scenario has been created by our functional consultant , and asking me to trigger a workflow for approval ,  when employee fills that particular ISR FORM , workflow should start and to go his HR administrator , when HR administrator double click on workitem he should get the ISR form in display mode  & also with some descpition text  is to be added in the screen (like user decision description ) with approval button ..... my question is how to trigger a event from in form scenario ? , how to bring the FORM screen to display mode  to the HR administrator ?
    regards
    surya

    Hi Surya
    The BO for ISR forms is BUS7051 - Notification. Turn on the trace via SWELS and create a PCR/ISR form and you should see the events being triggered in SWEL.
    Good Luck
    Ravi

  • How to fire an event dynamically in JSF Page

    Hi All
    How to fire an event dynamically in JSF Page?
    Thanks
    Sudhakar

    Hi,
    Thanks for the response. I mean to say, if I create the components dynamically then how can I fire events for those components.
    In otherwords,
    If I create the Button dynamically with particular ID being set to that component, then how can I call button action event when the button is clicked??
    Hope you understand
    What is the role of MethodBinding mechanism here??
    Thanks
    Sudhakar Chavali

  • Use of Events in OOPS ABAP

    Hi all,
        Can anybody please say me what is the exact use of EVENTS in OOPs ABAP. Can anybody please explain me with an example.
    Thanks in advance.

    hi,
    By triggering an event, an object or a class announces a change of state, or that a certain state has been
    achieved.
    Events link objects or classes more loosely than direct method calls do. Method calls establish precisely
    when and in which statement sequence the method is called.
    However, with events, the reaction of the
    object to the event is determined by the triggering of the event itself.
    Events are most often used in GUI implementations.
    Other external object models, such as COM, ActiveX Controls etc, also provide events.
    At the moment of implementation, a class defines its
    instance events (using the statement EVENTS) and
    static events (using the statement CLASS-EVENTS)
    Classes or their instances that receive a message when an event is triggered at runtime and want to react
    to this event define event handler methods.
    Statement : (CLASS-)METHODS <handler_method> FOR EVENT <event> OF <classname>.
    These classes or their instances register themselves at runtime to one or more events.
    Statement : SET HANDLER <handler_method> FOR <reference>. (for instance events)
    SET HANDLER <handler_method>. (for static events).
    A class or an instance can trigger an event at runtime using the statement RAISE EVENT.
    Both instance and static events can be triggered in instance methods.
    Only static events can be triggered in static methods.
    Events can only have EXPORTING parameters which must be passed by value.
    Triggering an event using the statement RAISE EVENT has the following effect:
    the program flow is interrupted at that point
    the event handler methods registered to this event are called and processed once all event handler methods have been executed, the program flow starts again.
    If an event handler method in turn triggers an event, then the program flow is again interrupted and all event handler methods are executed (nesting).
    Events are registered using the command SET HANDLER. Registration is only active at program runtime.
    Events cannot be persistent.
    You want to register an object to an event belonging to another object. The SET HANDLER... statement
    enters the registration in that object’s list. All handlers for one event are entered in this list.
    When the event is triggered, the list shows which event handler methods need to be called.
    Event handler methods are triggered by events (RAISE EVENT), although they can also be called like
    normal methods (CALL METHOD).
    The interface of the event handler method consists solely of IMPORTING parameters. Only parameters
    from the definition of the corresponding event (event interface) can be used.
    An event interface only has EXPORTING parameters and is defined using the EVENTS statement in the declaration of the event. The
    parameters are typed in the event definition and the typing is passed to the event handler method, that is,
    the interface parameters of the event handler method cannot be typed in the definition of the event handler
    method.
    In addition to the explicitly defined event interface parameters, the implicit parameter SENDER can also be
    listed as an IMPORTING parameter for instance events. This passes on a reference to the object that
    triggered the event.
    Events are also subject to the visibility concept and can therefore be either public, protected or private.
    Visibility establishes authorization for event handling :
    all users only users within that class or its subclasses
    only users in that class.
    Event handler methods also have visibility characteristics. Event handler methods, however, can only have
    the same visibility or more restricted visibility than the events they refer to.
    The visibility of event handler methods establishes authorization for SET-HANDLER statements: SET
    HANDLER statements can be made anywhere in that class and its subclasses only in that class
    <REMOVED BY MODERATOR>
    Edited by: Alvaro Tejada Galindo on Feb 14, 2008 2:45 PM

  • Portal Eventing in Webdynpro ABAP

    Hello,
    I am trying to implement Eventing in Webdynpro ABAP using 2 components ,Com1 serving as the source component and Com2 serving as Target. In Com1 I created a Inputfield and a button ,and then tied an action to the button and called the FIRE method of the IF_WD_PORTAL_INTEGRATION and sent the value in the Inputfield as the eventing parameter.
    In Com2, i subscribed to the event in the wddoinit() method and then defined an action for the same and got the parameter value sent in the Com1 and set the value in the context attribute in the Com2 which is bound to the inputfield.
    But still the value sent in Com1 is not displayed in the Com2 Inputfield.
    Any help would be highly appreciated.
    Thanks.

    >
    SAPEPDeveloper wrote:
    > Hello,
    >
    > I am trying to implement Eventing in Webdynpro ABAP using 2 components ,Com1 serving as the source component and Com2 serving as Target. In Com1 I created a Inputfield and a button ,and then tied an action to the button and called the FIRE method of the IF_WD_PORTAL_INTEGRATION and sent the value in the Inputfield as the eventing parameter.
    >
    > In Com2, i subscribed to the event in the wddoinit() method and then defined an action for the same and got the parameter value sent in the Com1 and set the value in the context attribute in the Com2 which is bound to the inputfield.
    >
    > But still the value sent in Com1 is not displayed in the Com2 Inputfield.
    >
    > Any help would be highly appreciated.
    >
    > Thanks.
    Hi I assume the following, please correct me if my understanding is not correct.
    1.First of all you try this in Portal.
    2.The moment you fire the event, the comp-2 view is active and subscribed to the portal event.
    If the above are true then tell me if the portal eventing enter into the action ?Have you checked in bebug that your action is triggerred on portal_event ?
    If portal event is action handler is called then if you have a importing parameter portal_event_parameter then your input value should be there.

Maybe you are looking for

  • Capture from Two Tables and Apply in one Table

    Hi All, Is it possible to capture from two tables (master and child table) and apply in one table? For example, 1. DEPT and EMP tables in source database with relation DEPT table structure is like DEPT_ID, DEPT_NAME, LOC_NAME EMP table structure is l

  • Bridge for Mac crashes constantly

    I'm running Bridge for Mac 3.8 on a 32 bit MacBook Pro with OSX 10.6.8. I have been trying to transfer music from iTunes to the Z2 without any success.  Every time it ends either with Bridge for Mac crashing or with a fail error.  If I attempt one fi

  • How to remove update notification?

    How to remove the update notification as it shown '1' at the top of app store icon? I was asked to update 'facebook' but then it requires my friend's id password instead of mine.. I've signed out all of his data from my iphone, but still can't be upd

  • Account problem, please erase double account!

    hi, i ve run into major account problems: now i am logged in as "peppermint". that used to be my account in 2005, and i posted very rarely. later i began using my actual account, lot of topics and i cant login with that cause it does autologin when i

  • Applying patches

    hi  experts, what are the steps has to take after applying patches thru sdm tool ? give me in detail , thanq