Events in LabVIEW 8.6 classes

I have class with a few members (something counter)

and I want to generate a user event when that Member has specific values.

Currently, I managed to generate the event only if I register the class event

in the Top Vi that use this class

can I register to the event inside the class itself, say within the vi ave I have reset for this class?

Thank you

Here is an example. Log the event in the VI initialize and close in the Shut Down VI. Example recorded in LV85.

Tags: NI Software

Similar Questions

  • Meet an applescript event in LabView 2009 (Mac OSX) VI

    I have a LabView VI that works constantly, acquisition of data at a remote location.  I recently bought a UPS for power cuts, and I would like to be notified by LabView by e-mail that an event has occurred.  Can I have the UPS software run an executable when there is a power failure, so my question is this:

    How to run an executable file (preferably AppleScript) and have it trigger an event in LabView 2009?

    The main VI is still running, and I would like to respond to an event and send a mail/text to the appropriate personnel, so that they can respond accordingly to the power failure.  In addition, if power failure, I can then stop the experience "smoothly."

    It seems that all the pieces have to exist to do this, but I can't find a way to get there.  Thank you in advance, this will make many people happy!

    News: Mac OS X 10.5.8, LabView 2009

    Hi jumpman Jr,.

    When you say that the UPS software may run an executable file, which means that it can run an executable of LabVIEW? If so, you can write a small executable of LabVIEW to send an email to a specified address. In the measurement of the notifying the main VI that is running, you can try to communicate between the executable and the VI using the methods of normal communication of VI at VI, i.e. global variables, functional global variables, shared variable network published, or even tax filers or queues. Then you can safely leave your main VI.

    Aaron P

    National Instruments

    Technical sales engineer

    http://www.NI.com/support

  • is it possible to put in place a control of the event in labview to create a string indicator when you press a button

    I'm trying to implement a user interface where an operator can set the column headers for a report and I use indicators of the string as the placement for the text in the column headers.  Given that many of them will have experience with Labview, I was hoping to set a button with the ability to add or possible delete a string indicator when you press.  Is it possible to set up an event like this?

    You cannot create an indicator of the string, but you can change the visibility of the existing volumes.

    For example, you can display an indicator of the string, giving the impression that his creating.

    /Y

  • Problem with the combination of LabVIEW (dynamic distribution) classes, statechart module and module FPGA

    LOCATION:

    -I am developing a software plugin based on plug-ins based on LabVIEW classes that are instantiated in running. Plugin real classes come from the plug in generic classes that define interfaces to the VI instantiation and can provide basic functionality. This means that many of the methods of the class are dynamic distribution and even methods of child classes can call the parent method.

    -Plugins top level (the ones directly accessible by the main VI) each have a run method that animates a plug-in specific state transitions.

    -Transitions of the plug-in data acquisition (DAQ class) class calls a method of the DAQ class that reads data from an FPGA card OR and transmits to another component via a queue.

    PROBLEM:

    -Higher sampling rate, a FPGA-to-host FIFO overflow occurs after some time. When I "weigh" the system just by moving a window of Firefox browser on the screen, the overflow is triggered immediately. I did not have this kind of problem in older software, where I was also reading a FIFO of FPGA, but made no use of LabVIEW classes or diagrams.

    SOLUTIONS I'VE TRIED (WITHOUT SUCCESS):

    -J' put the transitions in a timed (instead of a simple while loop) loop that I assigned specifically to an own kernel (I have a quad-core processor), while I left all the other loops of my app (there many of them) in any simple loops. FIFO overflow still occurs, however.

    QUESTION:

    -Does anyone have a tip how I could fix this problem? What could be the cause: dynamic distribution methods, the acquisition of data of state transitions or just the fact that I have a large number of loops? However, I cannot change the fact that I have dynamic distribution methods because it is the essence of my architecture...

    Tips are greatly appreciated!

    I've now changed the execution priority of all the screws involved in reading of the FPGA FIFO '(highest) priority critical time '. This seems to be improving the situation much: so far I have not a FIFO overflow, even when I move around the windows on the screen. I hope it stays like that...

  • Event of LabVIEW transformation in an external library (DLL) :-(locks


    Yes, I tested this solution and got to work.

    I see why Labview creates its own queue for events in such a way that callback events are not processed within the DLL code is and are waiting to return in Labview.

    And when I call the DLL inside another function that executes another asynchronous process (enumeration) this way active queue processing in the application.

    It's a strange and not obvious situation.

    I only discovered that all of a sudden this possibility during debugging.

    I don't see other solutions and cancel this topic.

    Best regards

    Anatoly

  • simulate the arrow key events in labview

    Hello

    I'm trying to simulate the events of arrow (left, right, up & down) key in labview. Lets say, I wish that the events to occurred when a cursor beyond a certain threshlold (later I'll interface with a data acquisition).

    I found this example but I can't find out how to move the arrow keys (and I don't have any experience with User32.dll):

    http://zone.NI.com/DevZone/CDA/EPD/p/ID/3711

    I would really appreciate the help.

    Thank you very much

    I searched for a while, but I don't remember the forums where I originally found this VI so I can't give credit due.

    It is similar to the VI you posted simulating a keyboard, but it would proably your needs better

  • Can pass you an event to a "global defined class function"?

    I have a class file that is defined in my package as MyGlobals.as.

    I have several functions defined in this way:

    public void myFunctionName(e:TouchEvent):void {}

    do things

    }

    (I tried add/remove 'static' and 'dynamic' to no effect).

    I try to call an event of button on the main timeline in this way:

    myObject.addEventListener (TouchEvent.TOUCH_BEGIN, MyGlobals.myFunctionName);

    (I tried to remove the class name to no effect).

    When I compile I get error 1046: Type was not found or is not a constant of compilation: TouchEvent. This error occurs on the function definition in the class file.

    What syntax/concept hurt me? The functions have been working well when I was using constants in the timeline panel, but I need to be able to reuse these functions over and over again, so I wanted them to be able to contact event variable so that I didn't have to write a different function for each key event.

    I tried Googling "error 1046" but I can't find anything useful. I guess that I do not understand some basic concept. Can you point me in the right direction or tell me what I should be Googling for the answer I'm looking for?

    Thank you very much!
    Amber

    Hello

    seems that you have to add: import flash.events. TouchEvent; to the top of your MyGlobals to get rid of the 1046 error class.

    and add static front public void myFunctionName(e:TouchEvent):void { }

  • To access the event listeners in the custom class

    I am a construction and film using the classes customized for the first time. I built a custom class and bound a clip in my film for her so that the color of the text in the video will change when he is overthrown. I have 10 occurrences of this clip in the film, so it saves me a lot of code. Instead of writing 10 to ROLL_OVER event listeners and 10 more for ROLL_OUT (as I have done in the past), one for each instance of the clip on the scene, I wrote now event listeners and the corresponding functions in the custom class. So far, so good, everything works fine. When I ride above and outside on one of the 10 instances of the clip on the stage it changes color. See code attached.

    However, according to what is happening in the film, that I sometimes need to turn off the headphones of events on one or more video clips. So, I wrote the code in the movie itself to remove event listeners of the instance of the clip that I need to disable. See code attached.

    But, alas, it does not work.

    I get this error:
    ReferenceError: Error #1065: Variable turnWhite is not defined.

    I thought that by the 'public' method in the custom class, I would be able to call from the film, but I do not. Any help or advice would be greatly appreciated. Thank you very much.

    Ned, thanks for your help. I was able to understand. Your code has been helpful, and I've used something similar to what you suggested.

  • Event handler to indicate a class is over

    I use a class (i.e., Grader) to process information before calling a function (i.e. updateScore) who needs to use a property of the class (i.e. myGrader.runningTotalScore). However, the property is not fully updated within the class before it is required by the function. How can I delay the call of the function until the class has completed all its operations?

    private function updateScore (): void {}
    var runningTotalLine:Number = myGrader.runningTotalScore / studentsGoal * 200
    }
    myGrader is new grader (wrongScoresArray, usersAnswers, correctScoresArray, textParser1.answersArray)
    updateScore()

    Create a custom event, and then the updateScore() function can be called from the event handler. See the FB help on custom events.

  • Sending events from instances of the class

    Hello
    I have problems with dispatching events from instances of class.
    In a simple MXML application, I added an event listener for a custom event.
    In accordance with the rules of good practice MVC, I have a template with a single instance (singleton pattern) class. This instance has no reference to my MXML component. When my model receives the data from the server, I want to send an event of this forum (which isn't in the displayList!). I could solve that problem with a model of the observer, but there is no way to any shipment of the event?
    Help much appreciated!
    Dany

    Hello Cesare,

    It works indeed! Thanks a lot for your help here!

    Dany

  • Events and listeners between custom classes

    I have a project that I worked on for weeks that I have yet another problem with. I am trying to learn AS3, that is why it takes so long, but that is not important for this position.

    I wanted to create a custom event class so that I could make sure the event did not interfere with other 'COMPLETE' events that are passed between the classes. In other words, I have a few things to finish before a function called... we're loading XML and another is a police. So, I thought about creating a custom FontLoaded class that extends the event and do type something like "FontLoadedEvent.LOADED". In this way I could listen to 'Event.COMPLETE' XML and this event of police also.

    Please tell me if I'm going down the wrong path here, but I don't seem to receive in the event of a return to my new custom event. Also, how we detect if it is being distributed differently if the eventListener is triggered? Other ways to test this?

    You can follow the event to see if it has sent.

    In addition, this isn't a good deal to create a new event. Custom events are used to store additional information. MouseEvent exists because the event has not localX, locally, properties etc. Since you don't seem to be throwing additional properties, you can use a regular event.

    trace (dispatchEvent (new Event ("panelFontsLoaded"));

    addEventListener ("panelFontsLoaded", onFontsLoaded);

    Static Consts are used to help debug the typos. The type of event is just a string, often stored in a const.

  • How to disable by default led event in labview

    I have 1 Led in front before, when I click on that it will change the State. This should not happen to me. How to disable it. Here the Led property must be not indicator control.

    Thank you best regards &,.

    Harish G.

    Your light is a control. Make it rather an indicator (with the right button of the point... change indicator).

    Of course, if it's an indicator that you can no longer use a value change event. You can use a mouse down event.

    What is a LED? In the case the more simple you could just color the State ON and OFF of the same dark green...

  • Record event blocks LabVIEW if the event Type is not selected.

    Hi I think that found a possible bug in LV2011 SP1.

    -Thread a property node of event Reg on the dynamic event record Terminal of a structure of event

    -Add a case to the event

    -Click on the dynamic event

    -LV accidents

    The source code included, try adding the unspecified event and look like LV breaks down.

    BR,

    / Roger

    Hi Roger,

    I doubt it. If you first select the event in the node property and then add the event to the event, you do not get an accident (I don't have at least let me know if you do). However, if boring and annoying is when it happens, there is a simple solution to the problem, which probably means that it will not be fixed on the previous version.

    Johan BR

  • How to read the windows event in labview

    I want to read the windows event viewer. Evt file to get information on the windows stop, start, restart... etc.

    and save it in my database.

    You might also take a peek at Microsoft LogParser. You can call the executable from the command line using System Exec. Supposedly, it also has an ActiveX interface.

  • TestStand and LabVIEW treat differently polymorphics with instances with bodies of private classes.

    I have a class of LabVIEW and the class contains a method that is a polymorphic VI, and that polymorphic instances has. If I put the scope of Private, and the polymorphic bodies access to the public, then I can force developers who use the class to use the polymorphic VI (and not to call directly the instances). It's great. I like that.

    but...

    I have build a TestStand API that uses a polymorphic and instances as described above. I create a time of LabVIEW, with a type of call class member, and I target my class. TestStand does not support polymorphic VIs, meaning that polymorphs or its instances appear in the name of the Member list.

    This means that, to support my LabVIEW users and my TestStand users, I need to create two separate APIs, which is not a place of happiness to be. No matter who encounter this and found a solution? Or I'm looking at this wrong?

    It dawned on me later that we could actually change TS to be a static link to a particular instance VI via the polyVI. After all, you can manually select an instance specific polyVI. It would be just a way to declare in TS "link to this particular instance of the polyVI." Allowing the TS to say "I'm going through a public interface to join a private function."

    So instead of linking "A.i" you could bind to ' PolyVI.vi: A.i ".

Maybe you are looking for

  • Library to transfer to the new computer

    I synced my music library (100 + concerts) on my new computer with a transfer cable iTunes displays all albums and playlists but will play no.  Error message:... original file is not found.  Ideas?

  • No sound or audio in flash.

    I have:Firefox 38.0.5Shockwave Flash 18.0.0.160 Problem is that when I watch a video that is NOT in youtube, it seems to be without noise.This happens on sites such as: Twitch.com kissanime.com (in this site have the ability to play videos in HTML5,

  • Home Edition XOOM: Software Update/update News

    Please subscribe to this thread. As any new update for the general public becomes available, it will be displayed here. To subscribe to this thread, click on the link to the right of "Receive the Notifications by Email" If you subscribe it will chang

  • Update blackBerry Blackberry Z10 10.2.1.2977

    My wife just download updated 10.2.1.2977 once the download is finished, I noticed our internet connection was VERY slow so I decided to go into the router and see if there's a problem. The router would not let me with the URL despite trying several

  • review during deployment - VCS Expressway

    Hello world!!! We knew the benefits of deployment - VCS Expressway. After reading "Cisco TelePresence video Communication Server Configuration of base (control with Highway) - Deployment Guide", I and my team are faced with the following: 1 - if we d