ActiveX - Get a reference to the control

Hi all

I need raise a value change event in a VI ActiveX of LabVIEW interface.

To do this, I think that I need to retrieve the reference to the control and then use the (signalling) Value property of this control.  Does anyone have any idea on how I could get the reference to a control through the ActiveX interface?

Any other suggestions on how I can trigger a change of value programmatically event are certainly welcome.  I tried the 'SetControlValue' call function but that does not raise the value changes.

Thank you

Zach

I don't know if I understand, but it looks like you are trying to control LabVIEW via its interface ActiveX from another program, such as C. In order to get the reference to a control so that you can access the value property (signs), you must first access reference front panel of the VI and then get the list commands (which is an array of references). You can walk through this table until you find the one you want, and then set the Value property (signs).

Tags: NI Software

Similar Questions

  • Bug found during the use of references to the control in subVis on Compact RIO?

    Hallo,

    I have a simple task. I want to read higher VI into a Subvi the real value of a control to a level. I want to solve this problem by using a reference to the control.

    I have attached a simplified program that shows this.

    But the problem is now. When I run the main VI on a cRIO-device, the indicator "DataByReference" is not updated with the actual value. Only when I opened during execution of the "RefMain.vi" too, then everything works fine.

    More strange thing is, when I run the VI of hand on the host PC, everything works well, also without having to open the "RefMain.vi" when executing.

    Someone at - it an explanation for this behavior?

    Thanks in advance!

    Bernd

    This isn't a bug.  See this explanation.

  • How to get a reference to the delivery of the program (not at base of LV)?

    Hello

    I need to create a LV application which will be:

    -Run external executable and not on LV. It has a window of the UI which will open

    -Open PS (no title, menus, etc.) and position it under the user interface

    -If the user moves main UI, LV app FP follows the window

    -If the user closes the main user interface, LV app closes and ends.

    App - LV does not display in the bar of tasks

    So, basically, I need to develop an application that will add-on to an existing GUI, so that together they look and behave like a single user interface.

    The main thing I am struggling with now is how to get a reference to the execution of UI that I call using the exec.vi system

    Help, please!

    What operating system? If you are on Windows, you can try to use the Windows API. Specifically, FindWindow to get a reference to both windows and SetParent to set the parent of one of the windows. This example gives you the basic idea.

  • How can I get my reference of the AdobePS free CS2 series?

    How can I get my reference of the AdobePS free CS2 series?

    It is not free.  downloads are intended for authorized users of cs2.

  • Get specific references for all controls

    Using slightly modified code from here, I'm generating a table of references of control on my main façade which is then transmitted to a number of subVIs. Although this feature does not work, it would be preferable to obtain specific references to controls (for example, Boolean RefNum instead of RefNum of control).

    Get these specific references seem possible using constants more specific class and the class specifier. However, the storage of data becomes a problem because I can use is more tables (because they are a different type of data). I don't know if there is another way to transmit these data. I experienced casting the RefNums in the variants, but to get the data of the variant, I need to know what type of RefNum I'm waiting order, of defeats the purpose of making it in the first place.

    A secondary problem is the names of references. The RefNums of control do not have names associated with them, and I do not know how to assign names to them. I tried again using variants and using the function name of the OpenG value data, but this block LabVIEW without indicating why.

    I have attached a version of my code that tries to assign names by using the name of the OpenG value data and build an array of variant. To run it, simple addition the VI as a Subvi has VI that has some Boolean controls on the front panel. My apologies for the crude State of the code - I'm still trying to find how to run things are a bit messy.

    I don't know if you're going to get much better.  There is really no way I know to have a completely flexible way to the building called cluster of references based on any set of given façade, Subscribe to this.

    I tend to do things the manual way (as there are also a bunch of references to elements of façade, that I wouldn't need).  I would like to do all the work for the grouping in a Subvi.

    I am attaching a zip file that contains the key to VI (unless I missed something) on the first project where I really tried to resume on the reference building.  The files are LV9.

    My main VI, I have the Sub - VI soon called to build the interface user of VI references during an initialization phase.  I pass the reference to the main VI in this sub - VI that generates all the references.  I worked on it as a master cluster that contains items that are arrays of references to related controls.  It uses an other sub - VI, called get references and names of labels that I created to help find witnesses.  I still need to use more specific class to get the property references, but I put only once at the beginning.  I then move this thread to cluster out and anywhere in my VI which should have access to references of the façade elements.

    I use arrays of strings to supply the names, I need to build and group references.  This allows me to ignore the controls, I don't care.  The drawbacks to my system, is that if I change the name of a command, I need to update the name in the Subvi.  And if I want to add all controls, not only do I need to add the label to search functions names, I also need to update my cluster typedef (and you absolutely want it is a typedef) to add a place to store the new reference.

    I hope that gives you some ideas.  It worked for me and I will probably use the scheme on another project (or even rewrite other projects using this diagram.)  If there are ideas of improvements, I'd be happy to hear.

  • data not getting not displayed in the controls present in the tabs

    Hello

    I am facing problem in data binding to different controls existing in different tabs of a page of data. I can see the values of the controls on the first tab, but not in the other tabs. And at the same time, I can get the values of the same data if grid is present in the tabs later...

    Please guide me...

    To do what you want, set creationPolicy = "all" on the TabNavigator.

  • Reference to the control on the main façade fails the Subvi front is closed?

    Hi all

    I meet a strange bug. In my code, I use a Subvi to control a piece of hardware. The Subvi has commands for all functions of my hardware.

    I changes the value of one of these controls in my main façade by running a reference to a button on my main façade in the Subvi, grabbing the value of the button with a property node, then update the value of the Subvi control using a node property signage.

    This works very well when my Subvi front is open, but does not work the Subvi front closing.

    I am new to labview, so any help is appreciated.

    Thank you

    Rachid

    This event triggers a series of writing for the real hardware. The material is sent only a command when something changes.

    My code is made up of handlers inside functional global variables. In this way, I can send different parts of code of different orders (example: reset and reset) with the events generated by programming.

    The value of the wheel of the page main itself, according to my probes, getting through. It's the Subvi button that is having a problem.

    I work under a certain pressure of time pretty important, so I managed to convince the boss that the front panel of the Subvi open does not violate the requirements of the application. I guess this has solved my isse.

  • Cannot install updates. I get a reference to the code 646 and the message: Windows update encountered an unknown error

    Remember - this is a public forum so never post private information such as numbers of mail or telephone!

    Ideas:

    • You have problems with programs
    • Error messages
    • Recent changes to your computer
    • What you have already tried to solve the problem

    See this response archived from a previous thread:

    http://social.answers.Microsoft.com/forums/en-us/vistawu/thread/21092c30-da71-4b7c-B242-1b32b28242bc>

  • Is it possible to get a reference to the main timeline in an external class?

    Hello
    After spending over 2 hours on google on how to access the pit of the main timeline an external class
    I have not found any solution.

    Anyone know how to the main script in an external class to access?
    And you can see a movieclip (the name of the instance) of a clip that is drawn on the scene and not
    place dynamically with addChild in an external class?

    I hope to hear from anyone.

    I discovered a solution. Don't know if it's good, but it works for me.

    What you have to do is on your movie fla on any keyframe:
    Hello from the var: YourExternalClass = new YourExternalClass ();
    hello.someFunction (this);

    and in your external class, make a public service:

    public void someFunction (mainTimeLine): void {}
    trace (mainTimeLine);
    mainTimeLine.getChildByName("instancenameofyourmovieclip").alpha =. 5;
    mainTimeLine.getChildByName("instancenameofyourmovieclip").rotation = 30;
    }

    See you soon!

  • Get the reference to the type of control of def

    Hi all

    I've been using VI script to update certain parts of the report and have encountered a problem in a case.  I was not able to get a reference to a def control (.ctl file).  The control is simple enum, and I recorded it as a def type because I use several places in my main VI, although I don't think that my problem has nothing to do with the fact that it is a def type.

    I know how to get a reference to a VI (Open VI reference function), and I know how to get a reference to a control in a VI (function Open VI of the reference of the object), but not a stand-alone control.  Details of the help file for the Open VI reference function imply that I might be able to do this with instructions to "Strictly typed VI reference", but it let me only select files .vi and not the .ctl file.  Please notify.

    Thank you very much

    GSinMN

    You can open a typedef of control using the VI reference open and the path of control of wire on the way to the VI.  You can then change the control with scripts by obtaining a reference to the control on the front panel.  If you have a VI with control of typedef, you can get a reference to the typedef (not its instance) by obtaining a reference to the instance and using the Typedef VI or properties Typedef plotted for reference, or the path to the typedef.

    This can be confusing because a typedef is literally a VI without a diagram, and the script processes as such.

  • Is there a way to detect the mouse during the event for the controls within a tab control?

    I need to change the mouse pointer when it moves on controls that are found in the tabs.

    Now when the mouse passes over the tab, LABVIEW does not detect the saperately of controls for the mouse over event.

    Is there a way to do what I intend to do?

    Your problem is with the Panel.Controls [] property. It does not return the controls that are inside containers (tables, tabs, groups) and returns only the container itself. As illustrated by Sam, if you want the references to the controls in the tab, you must get the references to the pages and get the controls on each page and add them to your original table and do this recursively.

    You can either write a VI to do this (or search for it. There was posted here screw that analyzes recursively the FP for all control references) or everything just statically for this control a tab and move. There is also a VI delivered with LV that can help you with this, but I suggest that you not use, because it will be difficult to operate if you generate an EXE file.

    And I also recommend the Tool of Capture of Code.

  • Avoid to get two theards at the same time

    Hello

    I was wondering how to avoid to run two threads at the same time in teststand. When I using teststand, I found it can run two threads in simultaneity.for example, I can open a file sequence, using single-pass enter point to run a theard, when this theard is not finished, I use single-pass or TestUUTs enter point to run other theard. I want to avoid this case. Is there settings, we can get motor teststand to tell me a thread is running or not?

    Thank you!

    You write a custom user interface? If you use an application Manager (all the example user interfaces and the sequence editor to do), you can see:

    ApplicationManager.Executions.Count > 0

    If you use just the engine that you can keep the number of executions by increment your account upon receipt of the UIMsg_StartExecution UIMessage and reduce your number when UIMsg_EndExecution is received.

    If instead you want to determine the number of executions of a sequence running, you can use RunState.Engine.GetInternalOption () to get a reference to the Application Manager (at least of the UIS and the sequence editor that use an Application Manager) and then do the following ActiveX to get the Executions.Count property.

    Hope this helps,

    -Doug

  • Programmatically disable the controls on the front panel

    Hi all

    I have a case in which I need to activate the control of front panel during scanning or taking data and when this case is false / when not not taking data. I try to make the Subvi usng vi reference, the node property, making the label controls and disbaling it. I want to disable the control listed in the table during the real deal and allow them to return to the case of fake. But right now, it of not working and hangs my main program. Please see the vi attached and help find where I am doing wrong.

    Thank you

    The best way would be to create an array of references to the controls you want to mess with beforehand.  I say that because I'm guessing that you have several groups of controls you will be turn on/off at the same time.  If you have a table of these controls already created, then just run the table in a loop FOR and use the Disable property.  I made a few minor cleanups in your current VI.  I got rid of the outermost case structure since the two cases are essentially the same thing.  A selection function allows to choose to enable or disable.

    NOTE: the forums are screwing again and not let me post a VI.  Change the extension back to vi to open it in LabVIEW.

  • How to create a reference in the schema when running?

    Hello

    I make a program and I would like to create references to objects at run time, y at - it a function in labview that lets do?

    Thanks in advance!

    It of maybe just me, but what do you mean by "cluster objects"?

    What is a cluster as terminal? If this is the case, then just to let you know, that a cluster cannot change the size/number when running, you need a table for this.

    Where are you what to change the visibility for?

    If it's a 'high-level' orders/lights vi you what to change the visibility on a Subvi, then you must provide the sub - vi with an array of references to the controls/indicators.

  • Error: System 32\nvcpl.cpl. Cannot open the control panel.

    While trying to open Control Panel with Windows XP Professional, I get this error and the Control Panel does not correctly or at all.

    None of your Control Panel options don't work or is a certain (s)?

    Is that really you see the exact error message?

    The file nvcpl.cpl belong to the graphics card NVIDIA and the NVIDIA Control Panel Applet

    If you have any NVIDIA products installed, you should tell us more about your system as follows:

    Since the Microsoft Answers forum does not have any kind of information system request when a new question is asked, we know absolutely nothing about your system.  Not knowing the basic information a problem prolongs the frustration and the agony of these issues.

    Thank you MS Answers, allowing the resolution of simple problems as frustrating and a lot of time as possible.

    Provide information on your system, the better you can:

    What is your system brand and model?

    What is your Version of XP and the Service Pack?

    Describe your current antivirus and software anti malware situation: McAfee, Symantec, Norton, Spybot, AVG, Avira!, MSE, Panda, Trend Micro, CA, Defender, ZoneAlarm, PC Tools, Comodo, etc..

    The question was preceded by a loss of power, aborted reboot or abnormal termination?  (this includes the plug pulling, buttons power, remove the battery, etc.)

    The afflicted system has a working CD/DVD (internal or external) drive?

    You have a true bootable XP installation CD (it is not the same as any recovery CD provided with your system)?

    Do you see that you think not you should see and when you see it?

    If the system works, what do you think might have changed since the last time it did not work properly?

    Now make some clarifications:

    Click Start, run and enter in the box:

    Msinfo32

    Click OK, and when the system info summary appears, click on edit, select all (Ctrl-A), copy (Ctrl-C) and paste (Ctrl-V) the information back here.

    For information about video drivers, expand components, click view, click on edit, select all, copy and then paste the information here.

    There will be some personal information (such as the user name and the name of the system), and anything that turns information private for you, simply delete the pasted information.

    This will minimize back Q & A and eliminate guesswork.

Maybe you are looking for

  • Error reading hard drive

    on startup, I get an error of hard disc.message also says press Ctrl/Alt/Del to restart.Sometimes it works and after doing this five or six times, the computer loads windows etc.Sometimes, I also have a read error when the computer is used and the sy

  • Resolution problem with Age of Empires on Windows 7.

    I can't get Age of Empires to work in a resolution of 1280 x 800; It plays only at 640 x 480. I tried all the different compatibility options, and none of them worked. This game worked on Windows Vista, but since I have upgraded to Windows 7. How to

  • Caught a virus. Want to just erase the HD and reinstall. Cannot get Windows original XP discs do. Help?

    Click son on some site that I can download a Trojan horse.  Disabled Malwarebytes and AVG update did not find. Saved that I need and now want to erase the hd and reinstall.  Cannot get computer to read what whatsoever. I myself once in safe mode, but

  • wireless lan driver problem

    My laptop HP 15-g009AX have a pblm with its wifi. I installed the wireless driver from the HP Web site button, but it has not yet detected my WiFi.I installed win 8.1 and the tower was bought by flipkart.it is powered by and a8 apu, 4 GB ram, radeon

  • HP probook 4520 s ram replacement for

    I have hp probook 4520 s running windows 7 ultimate 64-bit Intel core i5 cpu M460 2.53GH RAM 4 GB ATi mobility radeon HD 4300/4500 series graphics card Dedicated video memory: 512 MB 1719 MB shared system memory total avalible: 2231 MBMy quistion is: