Jump to content
Software FX Community

MultipleColors


User (Legacy)
 Share

Recommended Posts

Hello,

I have a realtime chart (2 lines) that adds a new point ( to each line)

every minute in an "AddTick" function.

Is it possible to use multiplecolors and then fire code like:

chartfx.multiplecolors = true

chartfx.opendataex COD_COLORS, 2, 0

chartfx.color(chartfx.npoints) = vbred

chartfx.color(chartfx.npoints + 1) = vbblue

chartfx.closedataex CODCOLORS

obviously the colors would be calculated depending on some sort of

condition, not always red and blue.

Any help would be appreciated, I am lost on how to use the multiplecolors

property.

Chase Gale

Link to comment
Share on other sites

Multiple colors are not supported in real-time charts as they don't scroll

with the data (after the buffer is full).

For a regular chart the code would look something like this:

chartfx.multiplecolors = true

chartfx.opendataex COD_COLORS, 2*NumberOfPoints, 0

For i = 0 to NumberOfPoints-1 Do

chartfx.color(i) = vbred

chartfx.color(i+NumberOfPoints) = vbBlue

Next i

chartfx.closedataex COD_COLORS

--

FP

Software FX, Inc.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...