LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to prevent users from changing indicator value

Hello all,

Is it possible to prevent a user from changing an indicator value? If it is, could you please show me how to do it? Any help would be greatly appriciate.

Hao
0 Kudos
Message 1 of 10
(3,821 Views)
Except for things like scales on graphs and charts, indicators can't be changed while a VI is running. To completely disable a control or indicator you have two options. From the front panel, right click on the control and select Advanced>Enabled State. From the diagram, create a property node for the control, right click on it and choose Change to Write. Right click on the property node again and select the Disabled property. Wiring a value of 0 to the property node enables the control, a 1 disables it, and a 2 disables it and grays it out.
0 Kudos
Message 2 of 10
(3,821 Views)
HaoLe,
Dennis answer is right on the target. However, here is another way of doing this. It might be what you are looking for. I hope this helps. /Mikael
0 Kudos
Message 3 of 10
(3,821 Views)
Thank you both very much for the info. I have followed Dennis instructions cause I forgot to mention that I'm still using LabVIEW 5.1; I could not open the file you attached Mikael.

Hao
0 Kudos
Message 4 of 10
(3,821 Views)
Good thing that your problem is solved. Yes, Dennis way of doing it is the way to go. All I did, which I should have mentioned, was that I put a transparent decorations box on top of the indicator. This method is primitive but it will work with anything because the invisible box blocks all mouse clicks. /Mikael
0 Kudos
Message 5 of 10
(3,821 Views)
Mikael,

That is really what I was looking for-block all mouse clicks. Do you know if LabVIEW 5.1 has the transparent decorations box feature? I don't see it in the Controls window's Decorations subpalete and I could not find it in the Help window's Index either.

Thank you in advance
Hao
0 Kudos
Message 6 of 10
(3,821 Views)
Just select any of the decoration boxes. Then you change its color to transparent by right-clicking with the paint brush cursor (tab a few times and it will appear). In LabVIEW 6.x the colors window looks like in the attached picture. The "T" in the upper right corner is the transparent color option. Make sure that both the border and the background are the same color (use the space bar as indicated). With transparent objects you can create many cool features in LabVIEW. Good luck! /Mikael
0 Kudos
Message 7 of 10
(3,821 Views)
Hao,

If you use a transparent decoration, make sure that you document that somewhere on the diagram. The person that has to change your program after you might think something is really screwed up if he wants to change the position, size, whatever, and isn't able to select it on the front panel.
0 Kudos
Message 8 of 10
(3,821 Views)
Good point Dennis. But I think that most users would realize it easily when it comes to moving or re-sizing the indicator. The reason is that you need the arrow cursor to move objects on the front panel and the arrow cursor over an invisible box will show its borders. If you drag it you will see that you move the box and not the indicator. But yes, the more you document, the better off you are. We all agree on that. /Mikael
0 Kudos
Message 9 of 10
(3,821 Views)
Thank you so much for your help Mikael, Dennis. I got it worked-this is a very cool method 😉

Hao
0 Kudos
Message 10 of 10
(3,821 Views)