C # render graph

I need to display a graph on my web page. I have defined a class file (in C #) that contains an event for rendering a graph (pie chart). In this case I am passing some value ie legend, which is a string [] and a value that is double [] to draw the graph. But I want that instead of inserting the value directly into the event, pass that value using some function like

public void insertvalue(string[] legends,double[] values)
{

}

      

how can i do this help me ???????? And I am using the Zedgraphweb control to display the graph.

+2


a source to share


1 answer


You can use a Key-Value pair like a dictionary and use that to plot a pie chart, something like <legend, value>

. You can also create a custom object that has two fields, Legend and Value, and use it to create a collection, such as an Arrayist or a simple array. You can find here regarding the ZedGraph control.



0


a source







All Articles