LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Exclude the color white from plot colors in graphs

I programmed a project with many graphs, where each graph has up to 128 plots.

It is always only one plot visible and the user can switch through the plots. I never configured anything for the colors, but left everything at the default settings. Now I got the feedback, that some of the plots are white, which is terrible to see on the white background.

 

Is there some easy way to exclude white as a possible plot color for all graphs in the project at once?

I actually do not really care about the colors at all, as long as they are easy to see, so it would be possible to set all plots to black (or dark blue, or anything else) because there is only one plot visible at a time anyway.

 

I want to avoid changing the plot color programmatically, I would like to set that fixed for the whole project. Is there some way to do this?

 

Best regards

0 Kudos
Message 1 of 9
(3,665 Views)

I use this method

plots.png

Message 2 of 9
(3,660 Views)

Hello Jusaca,

 

You should be able to just use the Plot.Color property on the active plot. 

 

This link shows how to set Programmatically Change Multiple Line Colors on a Chart or Graph.

---------------------
Patrick Allen: FunctionalityUnlimited.ca
0 Kudos
Message 3 of 9
(3,656 Views)

I guess that would work, but I still would have to do this for each and every graph I have. I hoped there was some way to set that for the whole project.

0 Kudos
Message 4 of 9
(3,651 Views)

@jusaca wrote:

I programmed a project with many graphs, where each graph has up to 128 plots.

It is always only one plot visible and the user can switch through the plots.


How does the user "Switch though the plots"? If there is only one plot ever visible, the graph should only contain a single plot. When the user switches, the data and plot name should be updated programmatically, reusing the same plot. It seems very inefficient and expensive to have the graph contain 128 more data than ever seen by the user. Massive data should only exist on the diagram (e.g. in a shift register or DVR), not in front panel objects!

 

Please show us some simplified code so we can give more specific advice. 

Message 5 of 9
(3,613 Views)

How about something like this then? It should find all XYGraphs in your project and color all plots. Just a sketch but it seems to work.color all xy graph plots in project.png

Certified LabVIEW Architect
Message 6 of 9
(3,597 Views)

In order to complete... here is a little VI I did to set a list of color that are easily distinguishable while removing the one you use.

https://lavag.org/files/file/301-55-easily-distinguishable-colorvi/

Benoit

0 Kudos
Message 7 of 9
(3,593 Views)

Hello Jusaca!

Did you manage to solve the problem?

 
0 Kudos
Message 8 of 9
(3,565 Views)

Oh, I'm sorry for not answering for so long.

I did postpone the solution of this problem, but i will try the way thols suggested.

0 Kudos
Message 9 of 9
(3,532 Views)