DSC - can't acknowledge or clear a user defined event

I wrote this code for alarms but now I have modified it to handle events.  So, first create the event (create alarm button), then try to acknowledge it or clear it.  There should be a time inserted for acknowledging and clearing.  It does't work.  I have used the exact event URL to acknowledge it.  Please help.
Thanks
Matt
Attachments:
User Defined Alarms.vi ‏52 KB

Hi Matt,
Thank you for attaching the new code, I didn't realize there was a path in that constant since the original box was so small. Part of the problem you are seeing actually lies within that path, you should be locating to \\*\Process Name\UserDefinedAlarm now that you switched from working with events to alarms. Also, you are still using the Set User Defined Event.vi and Read Events.vi, which need to move over to their Alarm counterparts.
Once you have those changes made, you need to alter the way you are trying to acknowledge the alarms. The problem isn't within logging the time but that the alarms are not being acknowledged at all. If you use the Read Alarms.vi and then wire the "alarms" output into the acknowledge function then it will acknowledge all of the active events (you may have to change the acknowledge type to Alarms). If you only want to acknowledge a single alarm at a time then you will need to trim down that cluster to focus on your selected alarm.
Finally, the way you are logging to the multicolumn listbox is not functioning correctly. I would suggest you look at the DSC Alarms Demo example (Help » Find Examples... » Toolkits and Modules » Datalogging and Supervisory Control » Alarms and Events » DSC Alarms Demo.lvproj). In that example there is a subVI, which is not part of the Alarms & Events palette but probably should be, named Format Alarm Data.vi. It is used in the first three examples under that project and should work better for logging all of your alarm interaction than searching through the database.
Regards,
Peter W.

Similar Messages

  • How can 1 make an object of user defined class immutable?

    Hi All,
    How can one make an object of user defined class immutable?
    Whats the implementation logic with strings as immutable?
    Regards,

    Hi All,
    How can one make an object of user defined class
    immutable?The simple answer is you can't. That is, you can't make the object itself immutable, but what you can do is make a wrapper so that the client never sees the object to begin with.
    A classic example of a mutable class:
    class MutableX {
        private String name = "None";
        public String getName() {
            return name;
        public void setName(String name) {
            this.name = name;
    }I don't think it's possible to make this immutable, but you can create a wrapper that is:
    class ImmutableX {
        private final MutableX wrappedInstance;
        public ImmutableX (String name) {
            wrappedInstance = new MutableX();
            wrappedInstance.setName(name);
        public String getName() {
            return wrappedInstance.getName();
        // Don't give them a way to set the name and never expose wrappedInstance.
    }Of course, if you're asking how you can make your own class immutable then the simple answer is to not make any public or protected methods that can mutate it and don't expose any mutable members.
    Whats the implementation logic with strings as
    immutable?
    Regards,I don't understand the question.

  • USER DEFINED EVENTS IN ALV

    HI ALL
    JUST WANT TO KNOW CAN WE HANDLE USER DEFINED EVENTS BY SETTING USER DEFINED PF -STATUS IN ALV
    FOR EG :
    call function 'REUSE_ALV_LIST_DISPLAY'
           exporting
                i_callback_program      = gd_repid
                I_CALLBACK_PF_STATUS_SET = K_STATUS
               I_CALLBACK_PF_STATUS_SET = 'ZTEST1'
               i_callback_top_of_page   = 'TOP-OF-PAGE'  "see FORM
               i_callback_u ser_command = 'USER_COMMAND'
                I_CALLBACK_USER_COMMAND  = K_USER_COMMAND
                 IS_LAYOUT                = GD_LAYOUT
                IT_SPECIAL_GROUPS        = KR_SP_GROUP
               i_grid_title           = outtext
               is_layout               = gd_layout
                it_fieldcat             = fieldcatalog[]
               it_special_groups       = gd_tabgroup
               IT_EVENTS                = GT_XEVENTS
                i_save                  = 'X'
               IS_VARIANT               = K_VARIANT
              IT_EVENTS                = KR_EVENTS[]
               is_variant              = z_template
           tables
                t_outtab                = it_ekko
           exceptions
                program_error           = 1
                others                  = 2.
      if sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      endif.
    endform.                    " DISPLAY_ALV_REPORT
    I HAVE MY OWN PF-STATUS IN WHICH I HAVE CREATED 1 BUTTON WHEN I GET THE OUT PUT AND CLICK ON THAT BUTTON THAN IT GOES TO STANDARD PROGRAM ....I WANT WHEN IT CLICK ON THAT BUTTON IT GOES TO MY Z PROGRAM HOW CAN I DO THAT ...
    IF POSSIBLE PLZ PROVIDE CODE OR SOME EXAMPLE .
    THANKS
    TARAN

    U can have button on application toolbar.
    You just have to use the new pf status in your report program.
    You should copy the 'STANDARD' GUI status from program SAPLKKBL using transaction SE90 >Programming SubObjects> Gui Status.
    Execute this transaction to get to next screen. select status using checkbox. click on GUI Status --> Copy.
    Enter your Z program name and the name you what for this status - you can keep it as 'STANDARD' to be simple.
    Then you can edit the new status to add or delete buttons. This will also bring in the standard SAP ALV functionality.
    Have a look at below code for using the new status.
    TYPE-POOLS: slis.
    DATA: i_qmel LIKE qmel OCCURS 0.
    data v_repid type repid.
    SELECT * FROM qmel INTO TABLE i_qmel.
    v_repid = sy-repid.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
    I_CALLBACK_PROGRAM = v_repid
    <b>I_CALLBACK_PF_STATUS_SET = 'SET_PF_STATUS'</b>
    I_CALLBACK_USER_COMMAND = 'USER_COMMAND'
    i_structure_name = 'QMEL'
    TABLES
    t_outtab = i_qmel
    EXCEPTIONS
    program_error = 1
    OTHERS = 2.
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    <b>form set_pf_status using rt_extab type slis_t_extab.
    set pf-status 'TEST'.
    endform.</b>
    FORM user_command USING ucomm LIKE sy-ucomm
    selfield TYPE slis_selfield.
    data lv_ucomm type sy-ucomm.
    lv_ucomm
    = sy-ucomm.
    CASE lv_ucomm.
    WHEN 'BUTTON'. "Double Click line Item
    **Write ur functinality here
    endcase.
    endform.
    Also have a look at below links.
    http://www.sap-basis-abap.com/abap/add-button-to-alv-toolbar-with-reuse-alv-list-display.htm
    ALV report
    I hope it helps.
    Best Regards,
    Vibha
    *Please mark all the helpful answers

  • USER DEFINED EVENT IN FUNCTION EXIT

    HI,
      CAN WE TRIGER AN USER DEFINED EVENT  IN AN  FUNCTION EXIT FOR XK01.

    Hi,
    if you identified the correct place then yes we can trigger the event. you want any workflow event to be raised.
    do you have any such exit with you.
    Regards
    vijay

  • Fire non-user defined event inside another event

    I want to call a normal/non-user defined event after an operation has occured inside a different normal/non-user definded event. Is this possible?
    The reason I don't want to use a user defined event is that if this can be done this way it would be much cleaner implemenation. Also, cleaner than using a sub-vi which would require a lot of wiring.

    From my experimentation with this, it appears that the fired event
    will not actually execute until the event currently being executed
    (the one that fires the other event) is completely finished. The
    "time" terminal of the second event idicates the time when it was told
    to fire, but it does not actually execute then. You cannot say do
    steps 1,2,3 in an event, temporarily leave that event to do code in
    another event, then come back to the first event and complete steps
    4,5. If the second event is fired after step #3, then steps 4 and 5
    will finish first before the second event executes. This contrasts
    with other languages such as Delphi were you can leave one event
    temporarily.
    On Mon, 25 Oct 2004 11:46:45 -0500 (CDT), chrisger o.email> wrote:
    >simple control (any type) you can write the desired value to the
    >"val(signaling)" property of the control. this changes the value AND
    >raises the "value changed" event, just like the user pushed the
    >button. then you can catch this event in the next turn of your loop.

  • How can I print document, based on user define template (Report Layout)?

    I want to be able to choose report layout, and print a document based on it. Can I implement it in my SDK code?

    Hi Shrem,
    I don't think this is possible with SDK code and PLD. You can do this if you're using a standard Crystal Report layout and you just send code to it using your code. Otherwise you can try and do this with user reports and queries in SBO itself without the SDK. But you're going to have to make all your layouts with more or less the same query and have where statements that limits the rows that shows on the report.
    Hope it helps,
    Adele

  • Can't bind status field in user defined table

    Hi!,
    I want to display the status of my document type user table, I added an EditText (unique id = txtStatus) control in ScreenPainter and Iam getting a Can't Bind error in this line of code. @Meta is my user defined table of type document
    ((SAPbouiCOM.EditText)oForm.Items.Item("txtStatus").Specific).DataBind.SetBound(true, "@META", "Status");
    Thank you!

    2 alternatives:
    1.Bind the Status field to "textStatus" EditText field in ScreenPainter
    2.Either in your code, bind the Status field to a ComoBox  field since it has valid values.
    Both works fine in my test.
    By the way, I get the same error Status field to "textStatus" EditText field.
    Kind Regards
    -Yatsea

  • Can Automation be used to send User-defined CC's to Environment objects?

    Hi, this is probably a really dumb question but I'll ask it anyway:
    I've bought a controller-environment for a synth (Alphajuno2, PG300 programmer) for Logic, the faders in the environment layer use sysex to communicate with the synth.
    Apparently it is possible to map an external midi-controller to these environment-faders, and that's all and fine, but what I'm after is a method of using automation to control the environment-faders. How would I go about doing it?
    I've only ever really automated some volume changes or plugin parameter changes, I've not yet automated faders in the environment, so how would I go about doing it?
    Would I create a fader which I'd link to the sysex-sending fader, and automate the fader, or maybe an environment-monitor (and add it to the arranger) and somehow configure a set of CC#'s to be automated with that arranger object, and then just cable them up to the various Sysex-sending faders (I do know enough to be able to set the input of those sysex-faders to match the CC#'s which the automation would be sending).
    Is this kind of "User-defined CC#'s in Automation" possible? How should I go about it?
    Message was edited by: esaruoho to further clarify it

    Is it just because there is currently no way whatsoever of Automation CC, and I should have known to use Hyper Draw to talk to an Environment object directly, which would then be connected to the Faders of choice?

  • Extending java.util.EventObject to create user defined Events

    Dear All,
    Can someone point me to a decent tutorial/article/example that explains how and when to extend java.util.EventObject class to create my own EventObject and Event mechanism.
    Please not the waterEvent, pipe and source example from the java beans tutorial :))
    regards
    Rupinder

    ??

  • Trigger a user defined event

    Hello,
     In my application, there will appear a dialog when an error occurs. I hope when pressing the "OK" button on the dialog can notify the main loop to stop, please advise how todo this.
    Thanks
    David 

    Hi DavidLee,
    see the two possibilities to solve your problem.
    Mike
    Attachments:
    EventStructure.PNG ‏11 KB
    Event2.PNG ‏17 KB

  • User-defined event assistance needed

    I have a 3D cast member that contains a bunch of animations
    defined by start and end points. For example, from 200 to 5000
    milliseconds is a rotation animation, and between 5001 and 6000 is
    a translation animation. I need to know when each of these
    animations have finished. I used animationEnded initially, but I am
    not sure how to set animationEnded to fire after a defined span of
    animation has terminated.
    Do I need to write a custom event to capture this? If so, how
    do you define an event? I am looking at using registerForEvent, I
    just don’t know how to write the event itself.
    Any help is appreciated.

    > For example, let?s say that you have a 2D sprite
    onstage, and it is rotating
    > through a script. Could you create a custom event that
    will detect when its
    > rotation is greater than 270? Can one write a custom
    event that detects when a
    > 3D cast member changes from a ?playing? state to a
    ?paused? state? I
    > understand how to register the event, it?s actually
    writing the event that I am
    > lost on.
    I think you're expecting something more than exists.
    You *the programmer* has to determine when to fire the event.
    It's not
    something you can ask to have automatically calculated for
    you. You have
    to write code to detect when the rotation goes beyond 270
    degrees, or
    when a 3D sprite's state changes. All of this will involve
    you polling
    for information required from a regular event like #exitFrame
    or a
    timeout object.
    When you detect that it's time to fire the event you use
    member.sendEvent(#eventName)

  • How to compose user-defined Event?

    I want to realize a event and event listener pair to work, the basic idea as follows:
        interface ConditionChangeListener extends EventListener {
             public void conditionChange(ConditionChangeEvent cce) {}
        class ConditionChangeEvent extends EventObject {
       class EventHandler implements ConditionChangeListener {
            public void conditionChange(ConditionChangeEvent cce) {
                    // do my work;
        class EventSource {
            // how can I fire a ConditionChangeEvent?
        }but how can I fire a ConditionChangeEvent in my code like above?
    Thanx

    class ConditionChangeEvent extends EventObject {[...]
    "yourEventQueue".dispatchEvent( "new
    ConditionChangeEvent" )
    or
    "yourEventQueue".postEvent( "new ConditionChangeEvent"
    }Is this enough or don't you know how to get
    "yourEventQueu" or is your problem how to create the
    new ConditionChangeEvent?Sorry for this answer - every time I see the word event I think one must talk about AWTEvent. But this is not what you are doing! So what you need is the whole
    "event generator idiom"
    described at the page
    http://www.javaworld.com/javaworld/jw-09-1998/jw-09-techniques-p2.html
    Hope now this is a real help for you

  • User defined event!!

    Hii all,
    I'm much more familier with events in java. Sometimes, i think, is there any way to define an event of my own or not??
    I've googled a lot but couldn't find anything valueable. could you else please help me out??
    thanks
    Dev.

    thanks yawmark ,
    actually Suppose the following code
    class AClass extends JFrame
        JButton b1;
        public AClass()
           b1 = new JButton("Press");
           b1.addActionListener(this);
        private void b1ActionPerformed(ActionEvent ae)
         // code to be performed....
    }What I'm actually want to know is, could i replace that <b1ActionPerformed> by my own event??
    thanks again
    Dev

  • User-defined include structures in FI

    Hi all,
    Can any body explain me about user-defined include structures in FI and how to do the enhancements..Plz suggest me by explaining with ABAP code. Plz tell me step by step.
    Thanks,
    Jack

    Hi Jack,
    Here they hav explained clearly pls go through the link below USER DEFINED INCLUDE STRUCTURES
    http://www.michaelmanagement.com/forum/uploads/20070621_164819_OSS_335065_-_Us.pdf
    Datasourceenhancement
    Below are the steps to enhace a data source.
    log on to r/3
    1..R/3sys, enter RSA7, SELECT UR DS(0FI_GL_4), SELECT DISPLAY ENTRIES,
    2.Select Delta Update and Execute.
    3.now u can see the records if at all they r available.
    4.Now Check The Data in u2018smq1u2019 in R/3 and Execute.
    5.Select ur Data source now.
    6.Display Entries.
    if at all any entries are there it display in the form of queues
    if u find any where data , it must be scheduled to ur data target using Info packages.
    Now let us see How to Enhance the Data source.
    7.R/3, Enter RSA6., select ur Data source, then Click on enhance extract structure.
    8. Now it populates a structure name. Like this u201CZADTFIGL_4u201D. Go with continue
    9.Give the Description.
    10. Under Component Give the Description of the fields u want to add Starting with ZZ
    11. Under component type give the concerned Technical names OF RELEVANT FIELDS in r/3. AND u201CENTERu201D
    12. SAVE
    13.Give The Package go with save, request no go with continue.(or create a new request)
    14. Now check and activate.
    15. go back from current screen select ds and go with change. Message continue, Request no continue
    16.now find ur newly added fields in ds, deselect hide flag and field only flag(check box)
    17. So far u have added field to ur DS, now u need to populate Data to UR Newly Added fields by writing user exit.
    Enter CMOD in R/3, give the project name , go with Create.
    18. Give the Description and Save
    log on to bw , rsa1-source systems, find ur ds replicate ds
    Now Devolope Required fields in Bw
    Add to ur communication structure,
    apply the Transfer rules ,
    Add to ur Target
    Recreate Update rules.
    Schedule the data..
    Regards,
    Marasa.

  • Modifying/Updating User Defined Field in a Scheduled Task

    I've written a notification task to send an e-mail to a manager who has a contract employee with a contract that is about to expire.
    Once we isolate a user who has a contract about to expire, we send a notification to the manager. The date that the notification is sent out should be stored in the USR table in a user-defined field, "USR_UDF_LASTSENT."
    Updating this USR_UDF_LASTSENT field is where I'm having difficulty.
    I've tried using the UserManager in a couple of ways. Suppose I've isolated a single user using SearchCriteria and the UserManager and have a single User object called "currentUser." I want to store a Date object in the user defined field "USR_UDF_LASTSENT". Date today = new Date();
    I've tried: currentUser.setAttribute("USR_UDF_LASTSENT", today); //This will run without error, but when I check the DB there is no change to the attribute.
    With a defined instance of UserManager userManager, I've tried: userManager.modify("USR_UDF_LASTSENT", today, currentUser); //This errored out with this error - oracle.iam.identity.exception.NoSuchUserException: IAM-3054135:No user found for the criteria USR_UDF_LASTSENT-9/24/13 2:58 PM.:USR_UDF_LASTSENT:9/24/13 2:58 PM. It looks like it's doing a search rather than a modification.
    I've also tried using the entity manager in the following way:
    Date today = new Date();
    HashMap<String, Object> mapAttrs = new HashMap<String, Object>(); 
    mapAttrs.put("USR_UDF_LASTSENT", today); 
    EntityManager entMgr = Platform.getService(EntityManager.class); 
    entMgr.modifyEntity("User", currentUser.getEntityId(), mapAttrs);
    But it returns with this error: Failed: oracle.iam.platform.entitymgr.UnknownAttributeException: User : [USR_UDF_LASTSENT]
    Is my entityType, "User" inappropriate in this case? What should be used here?
    How can I Set or Update this user defined field from a scheduled task?

    Thanks guys. I did go to Identity System Administration console and chose 'Export' from under "System Managment" which I believe Kevin may have been hinting at. I got an xml export of the AttributeDefinitions for our user defined fields. In this file, there was a header for the attribute I was looking for:
    <AttributeDefinition repo-type="API" name="LastSent" subtype="User Metadata">
       <multiValued>
       <backendName>usr_udf_lastsent</backendName>
    I put the string "LastSent" in place of USR_UDF_LASTSENT in the EntityManager version of my attempt at this task. I believe this is what Kevin and delhi were getting at.
    This didn't work:
    Date today = new Date();
    HashMap<String, Object> mapAttrs = new HashMap<String, Object>(); 
    mapAttrs.put("USR_UDF_LASTSENT", today); 
    EntityManager entMgr = Platform.getService(EntityManager.class); 
    entMgr.modifyEntity("User", currentUser.getEntityId(), mapAttrs);
    But this did:
    Date today = new Date();
    HashMap<String, Object> mapAttrs = new HashMap<String, Object>(); 
    mapAttrs.put("LastSent", today); 
    EntityManager entMgr = Platform.getService(EntityManager.class); 
    entMgr.modifyEntity("User", currentUser.getEntityId(), mapAttrs);
    I wonder if currentUser.setAttribute("LastSent", today); would work... Hmm.

Maybe you are looking for