rhswain Posted April 28, 2009 Report Share Posted April 28, 2009 I have a chart with two constant lines that I create with OpenDataEx COD_CONSTANTS 2I can clear both lines by using ClearData CD_CONSTANTLINESBut what if I want to clear just one line while leaving the other visible?I have tried setting the Value of one line to CHART_HIDDEN, but that makes the line appear at the bottom of the Y axis! I can set the value to -99999, which does hide the line, but I am uncomfortable with that "solution" since my real data might include -99999.Is there a clean way to clear/hide just one constant line? Also... Another question about a Constant Line: If I have a chart with both a bar chart and a Constant Line, is it possible to have the Line appear "under" the bars of the bar chart? Right now, my Line appears "on top" of the bars. Can the "Z-order" be changed? Thanks in advance for any help on this. Yes, I know I should upgrade, but... Quote Link to comment Share on other sites More sharing options...
RandyJ Posted April 29, 2009 Report Share Posted April 29, 2009 Hi,The ShowLine property aAllows you to show or hide a constant line in the chart. However, please note that when you hide a constant line using this property, any text associated with the line will remain in the chart. You can use the ShowText property to show or hide the constant line text.Chart1.ConstantLines(0).ShowLine = FalseAs for your second question, I am afraid that would not be possible since this is by design.Regards,RandyJ Quote Link to comment Share on other sites More sharing options...
rhswain Posted April 29, 2009 Author Report Share Posted April 29, 2009 I don't see a ShowLine property for a Constant Line. Perhaps that was introduced in a later version...? The properties that I do see are: Axis Label LineColor LineStyle LineWidth Style Value Quote Link to comment Share on other sites More sharing options...
RandyJ Posted July 28, 2009 Report Share Posted July 28, 2009 Hi, In Chart FX 5.x, you can delete a constant line from the chart just by making it invisible. For the look of the chart I'm assuming you are using Chart FX 5.x, the code to hide a constant line is: ChartFX1.ConstantLine(0).Style = ChartFX1.ConstantLine(0).Style Or CC_HIDE ChartFX1.Refresh Regards, RandyJ Quote Link to comment Share on other sites More sharing options...
rhswain Posted July 29, 2009 Author Report Share Posted July 29, 2009 Ah ha! CC_HIDE is what I was missing. Thanks very much. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.