One thing that you could do is host the graph control in IE via the object tag and publish your data through DataSocket, then bind the graph to DataSocket. The article
Building an Interactive Web Page with DataSocket explains how to do this.
Another option would be that you could create a dynamic image in ASP from the graph. The graph's ControlImage method returns an IPictureDisp for an enhanced metafile. You could use a third-party component to create a .jpg, .gif, .png, or whatever on the fly and use the image returned from ControlImage to generate the graphic. It's hard to provide an example of this without having access to
a third-party component that can dynamically generate images in ASP.
A third option would be to host the graph control in IE, then generate client-side script to plot data in your ASP code. Below is a simple example that generates code for an array of 100 random points. This example is not practical since you could already do that on the client, but the point is that you could do the same thing with the data from your database.
<html>
<head>
<script language="VBScript">
Function PlotData()
Dim data(99)
<%
Dim i
For i = 0 To 99
Dim value
value = Rnd * 10
Response.Write " data(" & i & ") = " & value & vbCrLf
Next
%>
graph.PlotY data
End Function
</script>
</head>
<body>
<object id="graph" classid="clsid:B68DBFAB-16A0-11CE-80BF-0020AF31CEF9" width="500" height="300">
<span style="color:red;">Unable to load the graph control.</span>
</object>
</body>
<script language="VBScript">
PlotData()
</script>
</html>
Hope this helps.
- Elton