LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Resizing a split chart

I'm trying to create a popup window with a chart that resizes as the user resizes the window. For a simple chart (1 source of data) it works very well (I'm using the algorithm from the knowledge base), but for a chart that has 2 sources, non overlayed it doesn't work quite right, it only resizes the top chart, while the bottom one remains the same (in height). How can I correct this? Another question that would sound a little stupid, but how can I force the popup window to close - the VI stops running, but the stopped window reamains opened.

Thanks
Ricardo
0 Kudos
Message 1 of 5
(3,059 Views)
Rciardo,

I attached here an example that I built in LabVIEW 6i, there are two VIs involved, Main Control.vi and Pop Up Chart.vi, you have to place them in the same directory in your drive, and run the Main Control.vi, leave those values as default and click in the button Pop Up Chart, this will bring the Pop-up window with a chart on it that has two sources and have the feature of stack plots. Try resizing it and you'll see that the whole windows maintains proportions.

I assume that your issue has something to do with the VI Properties set. Check the properties that the Pop Up Chart.vi has in Window Size and Window Appearance, for example I set Window Size as to current size when I created it, also I set Scale objects as window resizes, in Window Appea
rance I set Auto-Center, Use system color, allow user to resize window, show front panel when called and close afterwards if originally closed, which I believe that this feature is also going to help you to close the window when finish using it.

Take a look to it and if you need it to be saved in another version of LabVIEW please respond to this same posting and I'll get an email telling me of new activity, and if I don't reply just go to www.ni.com/ask and send us an email just saying that I have an example and the name of that example please.

Good luck!

Nestor Sanchez
Applications Engineer
National Instruments
Nestor
Download All
0 Kudos
Message 2 of 5
(3,059 Views)
For me it would be better in LV 5.1.1
Thanks
Ricardo
0 Kudos
Message 3 of 5
(3,059 Views)
For me it would be better in LV 5.1.1
Thanks
Ricardo
0 Kudos
Message 4 of 5
(3,059 Views)
Ricardo,

Sorry for the delay, I just got back, here are the VIs saved in LabVIEW 5.1 version, I already test them. So you have to run the "Main Control.vi", then press the button "Pop Up Chart" and the Chart will appear... try resizing it from the corner and you'll see how everything is scale including both windows of the Chart. Try this examples...

For the close option, see how I implemented it, in the VI Setup (right click the VI icon top right corner), in the execution options you have the open front panel when called and close afterwards options checked. See if this works for your application. Good luck!

Nestor Sanchez
Applications Engineer
National Instruments
Nestor
Download All
0 Kudos
Message 5 of 5
(3,059 Views)