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

Message ListMessage List     Post MessagePost Message

  More praise
Posted by Darryl on Mar-09-2011 02:05
Attachments:
I am sure you are accustomed to people using your products in unexpected ways, but I thought I'd share this because I was so surprised (and pleased) that it worked so well.

Our customers have requested that users be able to choose data set colors and symbols. Choosing colors was a simple matter, and I modified the example built-in symbol chart from the ChartDirector help file to use as a symbol selector.

I was apprehensive about how to implement the entry into the selector and how to display the selected symbols but I tried this approach and, to my complete delight, it worked flawlessly:


VOID CDataColorDlg::UpdateChart(CChartViewer *pChartControl, int nSymbol, COLORREF clrSymbol)
{
    double nX[] = {0.5};
    double nY[] = {0.5};

    XYChart *c = new XYChart(24, 24, 0x0, 0x0, 0);
    c->setPlotArea(0, 0, 24, 24, 0x0, 0x0, 0x0, 0x0, 0x0);

    if(nSymbol >= 0)
    {
        c->addScatterLayer(DoubleArray(nX, sizeof(nX)/sizeof(nX[0])),
            DoubleArray(nY, sizeof(nY)/sizeof(nY[0])), "",
            SymbolArray[nSymbol], 12, ReverseRGB(clrSymbol), m_clrEdge);
    }

    pChartControl->setChart(c);
    delete c;
}


Yep, all those tiny boxes with symbols in them are charts :)
I've set up handlers for each control to invoke a chooser and reap the selection.

I had to come here and say thank you for providing a very nicely done product.

I've successfully added scroll and zoom to the real-time charts and that is working perfectly, too. I suppose it is a bit redundant to say that the accuracy of the data representation is spot-on (after all, it is what you folks do) but I think I've been conditioned to expect less because I've used other tools that leave much to be desired.

Many thanks to all of you for providing this product.
ColorAndSymbolSelect.png

  Re: More praise
Posted by Peter Kwan on Mar-09-2011 14:40
Hi Darryl,

Thanks a lot for your positive comment and sharing of your code and results with us. We are most delighted to see our customers using our products successfully.

Regards
Peter Kwan