ASE Home Page Products Download Purchase Support About ASE
ChartDirector Support
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  access to icons used by cd in download
Posted by Andreas on Jun-02-2017 18:20
Attachments:
Hi,
another question from my side :-)

I have a HTML legend on top of the chart. I wonder if it is possible to use the pretty icons chartdirector shows us in the download legend (see attachment) also in my HTML legend...? That was great because I have to show values (as bars) and accumulated values (as lines) with the same color and want to point out this in the legend....

Thank you very much!
Best Regards,
Andreas
Supp_Legend_Icons.docx
Supp_Legend_Icons.docx

17.82 Kb

  Re: access to icons used by cd in download
Posted by Peter Kwan on Jun-03-2017 05:10
Hi Andreas,

I assume you are referring to the legend box dynamically generated on the browser side using Javascript, such as those in the "Track Cursor" sample code. For these type of legend box, the icon is drawn using Javascript on the browser side. The server would not download the icons to the browser as separate images.

In our sample code, it typically draws a square box as the icon using something like:

viewer.htmlRect(7, 7, color)

You can change it to a line icon by using a long and thin rectangle, such as:

viewer.htmlRect(20, 2, color)

You would need to use your own code to keep track of which dataset is using which icon.

Regards
Peter Kwan