LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Strategies for locking down a Waveform Graph or a Waveform Chart???

Is there any slick, foolproof way to lock down a Waveform Graph, or a Waveform Chart, so that an end user can't left-click or right-click their way to damaging the axes?

I have attached three approaches to lock-down: The first approach uses periodic writes to Property Nodes, and while that allows the user to left or right click and very briefly change the behavior of the axes, any changes they make are quickly overwritten. The second approach uses an Event Notification Loop to catch any mouse clicks on the Chart and throw a pop-up window to remind the user that they are forbidden to change the axes of the Chart. The third method also uses an Event Notification Loop to catch any mouse click on the Chart, but then immediately bumps KeyFocus off to another Control on the Front Panel [note that while this works for left clicks, it doesn't seem to work for right clicks; also note that it does not work at all if the KeyFocus target is either an Indicator or a Hidden Control].

However, I'm not crazy about any of these approaches - they all seem like cheap hacks to me.

I guess I was wondering whether there's any nifty magic formula for telling a Waveform Graph or a Waveform Chart: "UNDER ABSOLUTELY NO CIRCUMSTANCES WHATSOEVER MAY YOU ALLOW THE END-USER ALTER YOUR AXES!!!"

If so, I haven't stumbled upon it yet.
0 Kudos
Message 1 of 18
(3,896 Views)
Simply put a tranparent object over the part that are to be protected from an user initiative. That could be a boolean, used to display a message suche as "DON'T TOUCH !), or to trigger some desirable behaviour...

CC
Chilly Charly    (aka CC)
0 Kudos
Message 4 of 18
(3,890 Views)
Is "transparent" the same thing as "hidden"?
0 Kudos
Message 5 of 18
(3,887 Views)
Of course, another approach would be to disable the graph, but there you loose every possible user interaction... except if you add some controls of your own to manage Y scale, color, point size and so on !
I believe my first proposal is the most straightforward.

CC
Chilly Charly    (aka CC)
0 Kudos
Message 6 of 18
(3,766 Views)


@tarheel_hax0r wrote:
Is "transparent" the same thing as "hidden"?




No : an hidden object is really hidden: you can't access it through the GUI. A transparent object is an object painted with the transparent color.

CC
Chilly Charly    (aka CC)
0 Kudos
Message 7 of 18
(3,887 Views)
> A transparent object is an object painted with the transparent color.

Is that the same thing as 16777216, also known as "2 to the 24th"???
0 Kudos
Message 8 of 18
(3,883 Views)


@tarheel_hax0r wrote:
> A transparent object is an object painted with the transparent color.

Is that the same thing as 16777216, also known as "2 to the 24th"???




You got it ! However, I believe it is more convenient to use the paint tool on the front panel 😄

CC
Chilly Charly    (aka CC)
0 Kudos
Message 9 of 18
(3,783 Views)
Hello,

Another way to attack this problem is to use another property node. You can create a property node for the waveform graph or chart. Then select X Axis -> Editable. Change this property to write and then wire a Boolean False to the property. You can repeat this for the Y Axis. This property keeps the user from being able to change the axes of the graph when it is running. Therefore, you could set the desired maximum and minimum values and then use the property node.

Thanks,
Caroline
National Instruments
Thanks,
Caroline Tipton
Data Management Product Manager
National Instruments
Message 10 of 18
(3,733 Views)