Jump to content
Software FX Community

RE: Random points on XY Line Chart?

Software FX

Recommended Posts

An answer to this question was already posted in the Server newsgroup.


In an effort to provide the most advanced solutions in conjunction with

the most comprehensive technical support structure, Software FX will

implement a Paid-Support Program beginning January 1, 2001 for all

existing and future Software FX application users. The specific details

of the Paid-Support Program will be released in an upcoming broadcast

e-mail, as well as on our website. Please be aware that the online

technical support web site at http://support.softwarefx.com will continue

to be available without charge.

Justin Trask

Software FX

Please reply to: cfxie@softwarefx.com

-----Original Message-----

From: Jon Olson [mailto:Jon_N_Olson@yahoo.com]

Posted At: Friday, December 22, 2000 11:20 AM

Posted To: Client

Conversation: Random points on XY Line Chart?

Subject: Random points on XY Line Chart?

I am tring to create a graph on a web page. I have downloaded the demo of

ChartFX 2000. I have a chart working with the following code, but it uses

the date/time values I have as a legend and NOT as data points. I need them

as data points because the times are not evenly spaced and also they are not

the same for all of the different series. This is written in VB Script.

(code at the bottom)

Any Ideas?




Jon Olson jon_n_olson@yahoo.com

sub btnShowValues_OnClick()

'IMASreturn2 is a ActiveX DLL that I wrote

set IMASreturn2 = Server.CreateObject("vbIMAS.vbIMASClass")

Const nMax = 10

Dim Values() 'Returns Data Values

Dim tStamp() 'Returns Time Stamp for value

StartTime = "2/1/1999 12:00:00 PM"

StopTime = "1/1/2000 12:00:00 PM"

'lstSelectedTags is a listbox on a web page

listcount = lstSelectedTags.getCount() -1

Set ChartFX1 = Server.CreateObject("ChartFX.WebServer")

'Use the CreateObject function to reference the Chart FX Data Provider

Set CfxArray = Server.CreateObject("CfxData.Array")

'Preform this loop on all labels in a list box

For i = 0 to listcount

'Set TAGName = to what is in the list

TAGName = lstSelectedTags.getText(i)

nResult = IMASreturn2.GetTagData(TAGName, StartTime, StopTime, nMax,

Values, tStamp)

'Add the Values and tStamp arrays to the data provider

CfxArray.AddArray Values

CfxArray.AddArray tStamp


'Let Chart FX take the information from the data provider

ChartFX1.GetExternalData CfxArray

'Make all of the series a LINE graph

for c = 0 to ChartFX1.Series.Count - 1

ChartFX1.SeriesĀ©.Gallery = 1


'Display the Series Count

Response.write "SERIES COUNT: " & ChartFX1.Series.Count & "<BR>"

'Set Chart as 2D

ChartFX1.Chart3D = false

'Create the Chart

Response.Write ChartFX1.GetHtmlTag("100%","50%")

End sub

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Create New...