<html> <head> <title>ASPChart Test Page</title> </head> <body> <p> Test page for passing data to the chart via an array. </p> <% ' Author: James D. (Jim) Miller ' 3:48 PM Wed August 24, 2016 Response.write now() & "</br></br>" Dim x_value, y_value, xy_points, n_points, Chart Set Chart = Server.CreateObject("AspChart.Chart") Chart.AddSeries 6 n_points = 300 ReDim xy_points( n_points) ' Generate some random plotting points. For i = 0 To n_points Randomize x_value = Rnd * 100 Randomize y_value = Rnd * 100 xy_points(i) = array(x_value, y_value, "", vbWhite) Next Chart.View3D = false Chart.LegendVisible = false Chart.AddXYArray xy_points ' Set the filename, save the image, and write the image tag. Chart.FileName = request.servervariables("APPL_PHYSICAL_PATH") & "\chart-images\test-chart.jpg" Chart.SaveChart Response.Write "<img src='chart-images/test-chart.jpg'>" Set Chart = nothing %> </body> </html>