Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Chart Control
  New Posts New Posts RSS Feed - Just one Label in a Series
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Just one Label in a Series

 Post Reply Post Reply
Author
Message
cpede View Drop Down
Senior Member
Senior Member


Joined: 13 August 2004
Location: Denmark
Status: Offline
Points: 666
Post Options Post Options   Thanks (1) Thanks(1)   Quote cpede Quote  Post ReplyReply Direct Link To This Post Topic: Just one Label in a Series
    Posted: 21 March 2011 at 9:33am
Can I add a label to just one point in a series. If I have 1000 points it would be nice to be able to select the points to have labels on, otherwise the graph gets overcrowded by labels.
 
-cpede
Product: Xtreme ToolkitPro (24.0.0)
Platform: Windows 10 (x64)
Language: Visual Studio 2017 (C++)
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 21 March 2011 at 10:02am
Hi,
 
With ActiveX version we are able to assign value to Point.LabelText.
Seems a space doesn't draw label.
 
So,   curPoint.LabelText = IIf((i Mod 10), <Your value>, " ") would assign a labeltext to every tenth point.
 
 
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....
Back to Top
cpede View Drop Down
Senior Member
Senior Member


Joined: 13 August 2004
Location: Denmark
Status: Offline
Points: 666
Post Options Post Options   Thanks (0) Thanks(0)   Quote cpede Quote  Post ReplyReply Direct Link To This Post Posted: 22 March 2011 at 5:31am
Hmmm, when I add a point I use SetLabelText to set it to _T("") or NULL, but in both cases it shows the values of all the point. And pStyle->GetLabel()->SetVisible(TRUE);
 
Is this possible at all? Other graph controls have custom labels, that you can add and attach to e.g. data points, axes etc., is that possible with this graph?
 
-cpede
Product: Xtreme ToolkitPro (24.0.0)
Platform: Windows 10 (x64)
Language: Visual Studio 2017 (C++)
Back to Top
Algae View Drop Down
Senior Member
Senior Member
Avatar

Joined: 08 January 2007
Location: United States
Status: Offline
Points: 217
Post Options Post Options   Thanks (0) Thanks(0)   Quote Algae Quote  Post ReplyReply Direct Link To This Post Posted: 30 November 2014 at 6:20pm
You've probably already resolved this but according to the CJ source if there is no string for the label it defaults to the value of the point.

You could try setting a non-printable character in SetLabelText. Since it's just a text field the label can accept any formatted CString. As long as there is a non-empty string it will override the label value default.
Back to Top
Arnoutdv View Drop Down
Groupie
Groupie


Joined: 29 September 2010
Status: Offline
Points: 38
Post Options Post Options   Thanks (0) Thanks(0)   Quote Arnoutdv Quote  Post ReplyReply Direct Link To This Post Posted: 16 December 2014 at 9:08am
A single space character as LabelText works for me
VB6 SP6, SuitePro 16.3.0 / 18.2.0, Win10/64
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.203 seconds.