Blink a control inside a subpanel: is it possible?

What is the right way to blink a control button inside a subpanel?
I have done a simple program that loads an external VI (containing a control and an indicator) inside a subpanel: when i try to blink the button, the property node returns TRUE value, but i don't see the control blinking.
Solved!
Go to Solution.
Attachments:
blink control inside a subpanel.vi ‏19 KB
OK Button.vi ‏7 KB

I'm not able to look at the code where I am, but it looks to me as if the vi in the sub-panel is not continuously running, but rather runs once every loop lap, not allowing it to run for a time long enough for the control to blink. 
If I'm right, make sure the vi in the subpanel runs continuously and start that vi once before going into the calling vi:s loop. Then set the blinking property as you already do now. You will have to read the 'OK led' by property node as well if you need it.
CLA
www.dvel.se

Similar Messages

  • Property node of a control inside of cluster inside an array

    I've created a control that has a cluster made of a Boolean, a String and a Numeric.  Then in my front panel I've created an array of these custom controls.  I would like to have access to the property of the controls inside of the cluster within the array.  ie, I want to change the color of the Boolean or make it blink, or "disable and gray" the text box.  I think I'm on the right track, or maybe I'm on the wrong path.  I've attached and example VI (testtray.vi) and the control that I'm using (UUT_Display.ctl).  Please excuse the use of a Flat Sequence Structure, I know it's poor programming practices, but I just wanted to throw something together.
    Any help would be appreciated.
    kevin
    Solved!
    Go to Solution.
    Attachments:
    testTray.vi ‏19 KB
    UUT_Display.ctl ‏5 KB

    I have enclosed a quick and dirty example of replicating the blinking in an array of clusters.  You can turn it on and off, but as we have noted, only for all of the elements.  If you were only showing one element of the array you could change properties based on which element was displayed.  You probably want to see them all.  In that case, you could use a cluster of clusters.  This may be a pain, but I would suggest that you use an array of clusters to do your manipulations.  Use Array->Cluster to convert to a cluster for display purposes.  Then you can manipulate the properties of the cluster.
    My guess is easier said than done, good luck.
    Attachments:
    Blink182.vi ‏98 KB

  • Set cluster's control value in subpanel

    Hi
    Is there a way to set the control value of a cluster in a subpanel?
    I enclose my vis in LV8.0
    Charly
    It's always sunny in California! Certified LabVIEW Associate Developer!
    Solved!
    Go to Solution.
    Attachments:
    Access cluster's ctr subpanel.zip ‏14 KB

    If you have a reference to the VI being put into the subpanel (which you must have or it wouldn't be in the subpanel, right?) you can use that to get a reference to the VI's front panel. This in turn will let you get an array of references to all the controls and indicators on the subpanel VI's front panel. Go through this array looking at the label:text property for each reference in the array until you find the one for the control that is the cluster.
    Now, use the To More Specific Class function to cast the cluster's generic control reference to a cluster reference. You can use it to get an array of all the controls inside the cluster. Now go through this array looking at the label:text property for each reference in the array until you find the one for the control thatyou want to set and there you are...
    Mike...
    Certified Professional Instructor
    Certified LabVIEW Architect
    LabVIEW Champion
    "... after all, He's not a tame lion..."
    Be thinking ahead and mark your dance card for NI Week 2015 now: TS 6139 - Object Oriented First Steps

  • How can I make a control inside a loop in a subVI change value when the calling VI's control changes?

    Hi.
    I think this is a pretty basic LV question, but I have not been able to find a good solution.
    I am attaching VIs that show the problem I am having, but obviously, the real application is a lot complicated, which forces me to try to do it this way.
    The issue is: I have a subVI with a Boolean control inside a loop.  When the control is true I want some action to take place.  When the subVI is run on its own, it works fine, acting properly when I set the boolean control to true via the LV FPGA interface from the host.  However, when I use it as a subVI, in which the top-level VI calls several instances of the subVI, I have the Boolean controls in the top level VI.  What is happening is that the false Boolean value with which the top-level VI starts is passed into the subVIs, and not updated, even though the control is inside the loop.
    Can any one suggest a good solution?
    Thanks,
    AlejandroZ
    Attachments:
    CallingVI.vi ‏7 KB
    subVI.vi ‏8 KB

    Hi.
    I know the example I posted might seem silly, but it was just to illustrate the problem I am having.  In reality this is the application:
    I have some LV FPGA code which uses a few FPGA IO to implement a serial link to communicate with a device.  Most of the time we are getting data from the device, so the serial link is used to send a read command, read in the data and put it into a FIFO.  However, I also wanted the VI to support sending data to the device, so I added an array control to put the data you want to send, and a boolean control to tell it you want to send it.
    Since sending and receiving data are done using the same FPGA IO, they cannot be independent operations, because they would garble each other. Therefore, in the subVI I have a loop in which I first read data if there is any to read, then check the boolean write control to see if there is data to write.
    As I mentioned, this works perfectly for talking to a single device.  However, we run into the issue of this topic when trying to replicate this for several devices.
    One easy solution is to not have the loop in the subVI, and have it in the calling VI (I am favoring this simple solution right now).  The only reason why I have not done this yet, is that the subVI has more than one loop, so I am going to have to create several subVIs.  I just posted to see if there was an even simpler solution...
    There have been some other possibly good solutions proposed here, though I am not sure if they work in LV FPGA.
    Thanks for all your responses.
    AlejandroZ

  • Usage of Apache Beehive JMS control inside Message Driven Bean

    Hi,
    I am developing a j2ee application using weblogic workshop 10.3. This application contains the following three projects.
    - J2EE Utility Project
    - Message Driven Bean Project
    - Ear Project
    In the Utility project I have created one apache beehive jms control. I am using this control inside the message driven bean application. I haven't got any issues during the development and deployment phase with the beehive control. But during runtime the apache beehive jms control is not getting instantiated and the mdb application is throwing the null pointer exception when the EJB container try to execute the methods on the control instance. I have used the declarative programming model to create the control instance inside the mdb application.
    I am using the weblogic 10.3 server for testing and I have created the 10.3 weblogic+workshop domain. By default it has the beehive libraries deployed.
    Can somebody help me out to resolve this issue?
    Regards,
    Bp

    You can get the message directly with getText() method. Following is the snippet of code.
    if (aMsg instanceof TextMessage) {
    TextMessage msg = (TextMessage) aMsg;
    String testMessage = msg.getText());
    Kishore.

  • Generating events from a control inside an array of clusters

    Hi, I have a question regarding UI events. I would like to capture a mouse down event generated in a string control inside of an array. Each element of the array is a cluster that has a Boolean control, a numeric control and a string control. When I try to add an event to handle the mouse down the only option available in the event structure is the one available for the entire array. If this is not possible to map event from the individual controls inside of the each cluster that are part of the array, could you provide with an alternate way of "knowing" when the string control is selected. The application has a touch screen without a keyboard and mouse. I need to display the touch screen graphic keyboard when the textbox is selected.
    Thanks,
    Diego F.

    I'm not sure, but I think your only option may be to do some calculations. The mouse down on the array will give the coordinates of the click in VI coords. You can get the coords and size of the cluster and the coords and size of the string using their property nodes. Then, you have to calculate whether the click was on one of the visible strings using addition, subtraction and quotients. Once you make a subVI out of this, it should be easy to use.
    You should watch out for the index display and the label, as they change the values of the coords. I'm sorry, I can't think of any easier way to do this.
    Correction - I just thought of one. If you use the KeyFocus property on the string inside the mouse down event, it seems to work. I'm not sure whether this will work when bringing the keyboard to the front, which is why I left the other suggestion in place. Here's my test (7.0)
    Try to take over the world!
    Attachments:
    key1.vi ‏29 KB

  • How to Programmatically Set the limit (max, min input) of a control inside a cluster?

    I want to programmatically set the limit (max, min input) of a control inside a cluster. (see attached VI).
    The max, min value will be read from a file. The input of the control must be within the range defined by the max and min value.
    Can anyone tell me how to do it?
    Thanks a lot for your kind help.
    Xiaogang

    Accessing the properties of a cluster (or array) is not a trivial operation until you have done it once. It's a two step (at least) process : first, ask for a reference (array of...) to the objects contained in the cluster, then tell LV what kind of object you are adressing.
    See the attachment.
    Chilly Charly    (aka CC)
             E-List Master - Kudos glutton - Press the yellow button on the left...        
    Attachments:
    How to set limit[1].vi ‏52 KB

  • Get the Type (U8, U16...I64) of controls inside a Cluster

    Hi,
    I have a cluster with several controls. 
    I would like to get the type of each control inside of it. To get the class is ok. This is simple and all of them are Digital. But I need to know if they are U8, U16, U32 ...... I64. 
    Any idea how to do this?
    Paul
    Solved!
    Go to Solution.

    I got it.
    I had to Convert the Element Refernce to Digital and then to use the property BitAccurateDataSize.
    I lost several hours to find the solution and in 5 minutes after I had posted my problem on forum I solved it . 

  • Make all controls inside a Groupbox or Panel unusable without disabling them

    Hello !
    I'm using Vb.net 2013 , NET 4.0.
    I'm trying to make all the controls inside a Groupbox ( or Panel) , unusable by users if a condition is true.
    This is the code that I'm using :
    Class NW
    Inherits NativeWindow
    Public Sub New(hwnd As IntPtr)
    AssignHandle(hwnd)
    End Sub
    Const WM_NCHITTEST As Integer = &H84
    Protected Overrides Sub WndProc(ByRef m As Message)
    If m.Msg = WM_NCHITTEST Then
    Return
    End If
    MyBase.WndProc(m)
    End Sub
    End Class
    Dim nwss As List(Of NW) = Nothing
    Public Sub block_area(flag As Boolean)
    If flag = True AndAlso IsNothing(nwss) Then
    nwss = New List(Of NW)()
    For Each c As Control In GroupBox1.Controls
    nwss.Add(New NW(c.Handle))
    Next
    Else
    If flag = False And (Not IsNothing(nwss)) Then
    For Each nw As Object In nwss
    nw.ReleaseHandle()
    Next
    nwss = Nothing
    End If
    End If
    End Sub
    The problem is that this code works for all controls , except the TextBox and DateTimePicker . These 2 controls remain always clickable and editable so usable by users.
     What can I do ?
    Thank you !

    Ok , friend , if you don't like this question , you can close it anytime. Next time when I need to make a question , I will be careful to do more hard questions like : " What will be the final result of a=1  a=a+1" . This is pure VB.net ,
    I think.
    I'm sorry if it upsets you that your code will not work as intended. Everyone here is just trying to help you understand that there is no good solution to your problem from a managed code perspective in Windows Forms. The best answers are to use a different
    presentation system or to spin your own custom control at the Win32 level (or buy one from someone else who has already done all of that work). The next bester answer is to fudge it with an image that you capture and update as appropriate.
    Reed Kimble - "When you do things right, people won't be sure you've done anything at all"
    ok , can you only give me a simple answer : What is the WM code that has to do with pressing keys from keyboards in a control ? I try to modify my code if you help me with this. Thank you !
    Hello Friend Here is my sample - very elementary, please make more good:
    Public Class clsControl
    Inherits Control
    Public actualControl As Control
    Private Property hiddenLock As Boolean = False
    Public Property lock As Boolean
    Get
    Return hiddenLock
    End Get
    Set(value As Boolean)
    If value Then
    Dim _bmp As New Bitmap(actualControl.Width, actualControl.Height)
    actualControl.DrawToBitmap(_bmp, actualControl.ClientRectangle)
    actualControl.Enabled = False
    actualControl.Visible = False Me.BackgroundImage = _bmp
    Me.Controls.Remove(actualControl)
    Else
    actualControl.Enabled = True
    actualControl.Visible = True
    Me.Controls.Add(actualControl)
    Me.BackgroundImage = Nothing
    End If
    hiddenLock = value
    End Set
    End Property
    Public Sub New(ByRef _control As Control)
    actualControl = _control
    Me.Controls.Add(actualControl)
    actualControl.Location = New Point(0, 0)
    actualControl.Visible = True
    End Sub
    End Class
    'FORM1 CODE
    Private _c As clsControl
    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
    Dim _txt As New TextBox
    _txt.Size = New Size(100, 20)
    _txt.Visible = True
    _c = New clsControl(CType(_txt, Control))
    Me.Controls.Add(_c)
    _c.Size = _txt.Size
    _c.Visible = True
    End Sub
    Private Sub Form1_Click(sender As Object, e As EventArgs) Handles Me.Click
    _c.lock = Not _c.lock
    End Sub
    Enjoy friend I spent time to make it work.

  • How can I set the caption text of picture controls inside an array or how can I choose which array element is assigned using the array elements caption text property.

    I have 8 picture controls inside an array and I would like to set the caption text of these controls.
    I have used the property node of the array and used the array elements property caption text to set the text.
    The problem is however that I set the same text to all the picture controls inside the array.
    My question is how to set caption text of specific elements (Picture control) that I have so far only been able to access using the array elements caption text property.

    Some more help
    1 You could use the caption of the array and place it in front of the selected picture and update that using property nodes.
    2 Like Norbett said if you use a cluster of pictures then their caption can be updated individually.
    Here is a an example that demonstrates the above
    David
    Attachments:
    Modify the Captions Of Pictures.vi ‏83 KB

  • How can I find the coordinates of individual controls inside a custom control?

    I have a custom control that contains 44 smaller custom controls.
    I can get the coordinates of the 44 embedded custom controls by getting the controls[] property of the main control, but I cannot find a way of getting the coordinates of the controls inside each of these smaller custom controls.
    Is there a way of getting at the coordinates of custom controls that are nested several layers deep?
    Erik.

    For future reference and for any LabVIEW users who have older versions here are the Front Panel displays before running the VI along with the Wiring Diagram with each of the four cases for handling the various types of ClassIDs that can contain child controls.  X1, X@, Y1, and Y2 are the coordinates of the top left and bottom right corners of each control.  These coordinates can then  be used to determine which control the mouse is pointing at.
    In my own project I did further evaluation to eliminate all parent controls (controls that contain other controls) and passed along only the controls that were end-nodes (controls that contain no other controls). Also, the control's refnum was stored for later use.
    The bottom picture shows the data gathered during the execution of this VI.
    Thanks again, Mike!

  • TABbing between controls inside a panel to controls outside a Panel

    Hi,
    I have a C# winform with few controls inside a Panel control and few outside it.The TABbing order traverse from controls inside a panel to controls outside a panel.
    Do we have any way to accomplish this.
    Thanks,
    sami

    If you set the TabIndex of the Panel control itself to for example 77, the outside control with TabIndex 78 will be focused when you tab out from the control within the Panel with the highest TabIndex. Also make sure that you set the Tabstop property
    of the Panel to true.
    So basically the controls inside the Panel have their own TabIndex series (starting from 0) and the Panel itself is part of the Form's (or parent control's) TabIndex series.
    It is just a matter of setting the values of the TabIndex properties correctly (and setting the Tabstop property to true for the Panel control).
    The other option is to replace the Panel with a UserControl.
    Please remember to close your threads by marking helpful as answer and then start a new thread if you have a new question.

  • Show hidden control inside editor

    Hi,
    i have following question! I created a user control inside the editor.
    It contains a cluster with several controls inside. Each control i can
    hide or show. But how can i get back the visibility of the cluster
    after i hide it? I didn't found an entry in the menu or anything else...
    Could somebody give me a tip?
    Thnx
    Henrik

    > sorry, i think that i explained it not enough.
    > What i want to have is a custom control which will show a bitmap when i
    > insert it into a vi. Cause the custom control is a cluster with 17
    > controls inside, i wanted to hide all controls and the cluster and show
    > a bitmap instead. The main reason is to hide the flowing data and to
    > reduce the size of the painted element in all this control using vi's.
    > The work i have to do in the custom control editor and there is no
    > diagram avaible. Later perhaps i have to make changes to the
    > cluster...how could i make it visible to change the data?
    >
    I'm afraid I'm still not sure what is being asked. Here is
    my guess. You want to use a strict typedef of a cluster of
    17 items. The typedef takes too mu
    ch room on your subVI
    panels. I'd recommend shrinking the cluster to clip out
    the items. This isn't a good idea in general because you
    can't see the items, but this seems to be what you are
    looking for. Make the cluster be about the size of a
    postage stamp and place a graphic or a comment label
    inside of it.
    When you are ready to show the items again, open the
    typedef and grow the cluster again.
    If the reason for shrinking the cluster is to minimize
    the memory impact, keep in mind that the panels that
    contain the controls are not kept in memory on most subVIs,
    and in fact, they aren't even compiled into a built executable.
    Greg McKaskle

  • Detect if any control inside a TableLayoutPanel is clicked

    Hello !
    Is there any way to detect if any  of the controls inside a TableLaoutPanel is clicked ?
    ( I mean without using Click event for each control ).
    I try using MouseClick's event of TableLayoutPanel , but this doesn't fire when a control is clicked.
    Thank you !

    Hello !
    Is there any way to detect if any  of the controls inside a TableLaoutPanel is clicked ?
    ( I mean without using Click event for each control ).
    I try using MouseClick's event of TableLayoutPanel , but this doesn't fire when a control is clicked.
    Thank you !
    Assuming that you set up your TableLayoutPanel purely in code, then it's just a matter of using AddHandler and direct it to
    the appropriate event handler sub. Do be sure that something (like the control's name) is unique - that's how you'll later identify it. You can also put a string (or any object, actually) in the .Tag property, but the name is the easiest.
    When calling it in code, call it using the event handler sub's name and for the two parameters, just use:
    SubNameHere(Nothing, Nothing)
    In each event handler code you just test whether or not the sender is null (directly) or use
    TryCast. If TryCast fails then it's because the sub was called in code; if it passes then test the name of the control in the casting operation
    and you'll know which control was clicked.
    Still lost in code, just at a little higher level.

  • How can I put a subpanel inside another subpanel?

    Hi,
    Is it possible to put one subpanel o several subpanels inside one main subpanel?
    Thanks,
    ToNi.

    DFGray wrote:
    You can create something in LabVIEW to do this, but it won't be trivial. Here are some things to point you on your way. I have not done this, so it is pure speculation on how I would go about solving this problem.
    You will need to know ahead of time the maximum number of windows you will want. On your front panel, create that many individual subpanels. You can hide the border and make them transparent so you never see them unless something is in them.
    When you load a VI into the subpanel, all you get is the panel, not the title bar. You will need to create a title bar with buttons and any border you want on the VIs in the panel area. This is tedious, but fairly straightforward, especially if you use system colors to make it look like a real title bar/border. You won't be able to make it look like an XP title bar unless you use bitmaps/picture control. If you go that route, you can probably even mess with the color map to change the bitmap colors when the system color changes (have to poll, no event for system color change).
    You can resize and move the subpanels using property nodes. Getting the info to do this could be tricky, however, since you may be coordinating mouse events from the top level VI and the VI hosted in the subpanel. Should be doable, though.
    One other method is to use floating windows, but move them on top of your main window so it appears to the user it is an MDI. You won't get clipping, but everything else will look the same and you won't have to jump through hoops to create title bars, etc. You will have to write a position manager to maintain the window positions, but that is probably easier than the tricks I discussed above
    Good luck. One final question - do you really need an MDI? Floating windows with clear labels are a lot easier. Do some polling of your users to find out what they like best, then go for it.
    You should using windows reparenting functionality through windows api dll calls. Reparenting is documented well on microsoft.com. Reparenting is how Excel opens multiple worksheets inside the Excel "parent" window. I have done this on a few of projects and it works far better than subpanels because it allows you to drag windows around within a parent application. They are also far easier to work with once you get the reparenting vi's correct (you have to do some messing with Z position and window activation to get them to repaint properly) because unlike with subpanels you can view a VI diagram while it is reparented with no problem. With subpanels I have also had problems with GUI controls driving event structures when a vi is in a subpanel.
    -Devin
    I got 99 problems but 8.6 ain't one.

Maybe you are looking for

  • How to change access path for 'where' clause by using HINTS?

    I searched a loooot of posts and haven't found a solution for my case. I don't even know whether it is possible or not. Is it possible to change the sequence of Oracle "Predicate Information"? Here is my SQL and Oracle's execution plan.   SELECT Max(

  • When I try record or watch any projects on iMovie it shuts down?

    This has never happened before but recently whilst trying to record or view projects on iMovie the app suddenly goes blank and my iPad returns to the home screen.How do I fix this?

  • HP Office Jet Pro 8500

    Can someone tell me why I only get pink print on my documents? I have new cartridges and they are inserted properly. Thanks, Bonnie

  • How to enable ibus in console?(finished)

    When I open the terminal console, I just want to use ibus to type.But after I use Ctrl+Space , I found that the ibus program didn't work.How can I use ibus in console? Last edited by metaphor (2012-02-22 17:33:32)

  • Authorization change price and qty for approval

    Hello all, please help me.. i have scenario Person A ( Requester ) : Create Shopping Cart Person B ( Manager    ) : Approved Person C ( Director )     : Approved , but this person have to change qty and price. In SRM, when Director approved , he also