Search found 6 matches

by Kyudos
Fri Oct 16, 2020 12:20 am
Forum: ActiveX
Topic: Drawing line between two cursors?
Replies: 3
Views: 39989

Re: Drawing line between two cursors?

Thanks Yeray - I used your example and it's working, up to a point. If I want the line to follow the cursor (e.g., draw it in OnCursorToolChange ), how do I erase the previous line before drawing the next one? So far it just keeps drawing lines... EDIT: OK - I found I can remove the old lines by add...
by Kyudos
Tue Oct 13, 2020 9:08 pm
Forum: ActiveX
Topic: Drawing line between two cursors?
Replies: 3
Views: 39989

Drawing line between two cursors?

I have two series on my chart, each with a cursor. Is there a way to draw a vertical line between the cursors to indicate the difference between the series values? (ideally, if I could display the value of the difference by the line that would be great). Something like the yellow line here: Untitled...
by Kyudos
Wed Sep 23, 2020 1:09 am
Forum: ActiveX
Topic: Chart Refuses To Draw Axis As Specified
Replies: 2
Views: 36749

Re: Chart Refuses To Draw Axis As Specified

Nevermind - I figured out I need to call AdjustMinMax after SetMinMax for the axis. This is not clear in the documentation, but arguably shouldn't be necessary? If "Automatic" is FALSE doesn't setting the min/max imply that I want to use those limits?
by Kyudos
Wed Sep 23, 2020 12:42 am
Forum: ActiveX
Topic: Chart Refuses To Draw Axis As Specified
Replies: 2
Views: 36749

Chart Refuses To Draw Axis As Specified

I've tried this using both TeeChart201664.ocx and TeeChart201964.ocx, but I can't get it to behave and can't seem to find a way to force it. I've turned off "automatic" and set my left axis limits manually. The editor shows that this setting has 'taken' but the chart refuse to draw to the specified ...
by Kyudos
Sat Sep 12, 2020 9:28 am
Forum: ActiveX
Topic: Drawing Polygon on Canvas in OnAfterDraw
Replies: 2
Views: 37275

Re: Drawing Polygon on Canvas in OnAfterDraw

After some trial and error I found this seems to work...is it correct? VARIANT pts; VariantInit(&pts); pts.vt = VT_ARRAY|VT_I4; SAFEARRAY* psa = SafeArrayCreateVector(VT_I4, 0, 6); if (psa != NULL) { LONG i; i = 0; SafeArrayPutElement(psa, &i, &p1.x); i = 1; SafeArrayPutElement(psa, &i, &p1.y); i = ...
by Kyudos
Wed Sep 09, 2020 8:59 pm
Forum: ActiveX
Topic: Drawing Series on Existing Chart
Replies: 3
Views: 40593

Re: Drawing Series on Existing Chart

Thanks Yeray - I tried this and got it working.

But then I found it was simpler to have fewer series' and use OnGetSeriesPointerStyle to do my end marks :)