Hi,
I have an ArrayList which contains integers, which I want to plot directly. For ex: if arraylist contains {2, 3, 5, 6}, The elements in the arraylist should be treated as values on y-axis and the graph plotted should have points (2,0), (3,1), (5,2) and (6,3). How can we do this ??
I saw some basic examples which use DataTable and values are added to rows and columns of DataTable, but i want to use arraylist directly. Is it possible ??
Any help will be appreciated.
yes, you can use an arraylist or any numeric array as the chart's datasource.
ArrayList list = new ArrayList(new int[]{1,2,3,4,5});ultraChart1.Data.DataSource = list;orultraChart1.Data.DataSource = new int[]{1,2,3,4,5};