Reputation: 30886
How do I call Zedgraph's function masterPane.SetLayout()
from Web C# Application?
Basically i'm stuck at step myMasterPane.SetLayout(g, PaneLayout.SingleColumn);
How do I create that variable g which is supposed to be a Graphic()
I tried Graphics g = new Graphics();
and Graphics g;
none of these work.
new Graphics() gives me Error 2 The type 'System.Drawing.Graphics' has no constructors defined
and anyways I'm assuming this needs to be initialized somehow.
One important difference that I want to do vs the example below is that I want to go directly from my master pane to an image using
masterPane.GetImage()
, my issue is I can't get that masterpane
setup unless I find a way to call myMasterPane.SetLayout()
I found this article but I can't get this working http://zedgraph.org/wiki/index.php?title=Use_a_MasterPane_in_a_web_page
Upvotes: 0
Views: 1415
Reputation: 161773
The page you linked to shows exactly how to do this. Did you try their example?
The example gets the Graphics
instance passed to it in the RenderGraph
event handler.
Upvotes: 1