cheekychops Posted March 27, 2009 Report Share Posted March 27, 2009 Hi Guys Can anyone give me a clue on how to add some on/off buttons to plots on a XY graph. Ex: if I have more than one plot on one XY graph, how can I add some buttons on the front panel so I can turn each plot on and off? Thanks Quote Link to comment
Francois Normandin Posted March 27, 2009 Report Share Posted March 27, 2009 QUOTE (cheekychops @ Mar 25 2009, 08:57 PM) Hi GuysCan anyone give me a clue on how to add some on/off buttons to plots on a XY graph. Ex: if I have more than one plot on one XY graph, how can I add some buttons on the front panel so I can turn each plot on and off? Thanks You can use an array of booleans next to the XY Graph legend. Match the "legend number of rows" property of your graph with the boolean array "number of rows" property to keep the array the same length as your number of datasets. I've built it in a XControl. Sorry I can't upload because it's proprietary and contains a few classes that make it not so plug n' play for a demo. Quote Link to comment
cheekychops Posted March 28, 2009 Author Report Share Posted March 28, 2009 Is there any other ways to do this? Thanks Quote Link to comment
mje Posted March 28, 2009 Report Share Posted March 28, 2009 All graphs/charts have two properties exposed via property nodes: Active Plot, and Plot.Visible. Use the active plot to set which plot you're dealing with, then set the visibility of that plot. See the attached VI. Download File:post-11742-1238121732.vi Quote Link to comment
cheekychops Posted March 28, 2009 Author Report Share Posted March 28, 2009 QUOTE (MJE @ Mar 27 2009, 02:40 AM) All graphs/charts have two properties exposed via property nodes: Active Plot, and Plot.Visible. Use the active plot to set which plot you're dealing with, then set the visibility of that plot. See the attached VI.http://lavag.org/old_files/post-11742-1238121732.vi'>Download File:post-11742-1238121732.vi thanks for the reply, can you please save that file in labview 8.2 or 8.5? thanks again Quote Link to comment
mje Posted March 28, 2009 Report Share Posted March 28, 2009 Saved in 8.2: Download File:post-11742-1238157638.vi Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.