Search code examples
c#zedgraph

Multiple Graph Panes Per ZedGraphControl?


Is it possible to put more than one graph pane in one zedGraphControl? So each zedGraphControl appears to have only one chart in a single control. I want to be able to add more than one chart to a particular zedGraphControl if that is possible.

Any help with this would be greatly appreciated!


Solution

  • You can add new GraphPanes via the MasterPane-Property of the ZedGraphControl class:

    GraphPane newPane = new GraphPane();
    zedGraphControl.MasterPane.Add(newPane);
    

    The GraphPane-Property of ZedGraphControl always accesses the first GraphPane in the MasterPane-List.