ryanlcs Posted July 29, 2009 Report Share Posted July 29, 2009 My Axis X is a consist of time line value, data comes in every hour. For specify hour, I wanted the background to be filled with certain color vertically, how can I achieve that? I am using Line Chart. Thanks. Quote Link to comment Share on other sites More sharing options...
ryanlcs Posted July 29, 2009 Author Report Share Posted July 29, 2009 Got it solved. Charts.AxisX.Sections.Add(New ChartFX.WebForms.AxisSection(cntCursor + CONST_START_STRIPE, cntCursor + CONST_END_STRIPE, System.Drawing.ColorTranslator.FromWin32(g_VerticalRegions(cntCursor)))) Another small problem, initially I had the font on Axis X set to bold, but somehow, after applied this AxisX.Section, the font on this section become normal rather than bold, the rest on the value remain bold. Bold setting: Charts.AxisX.Font = New System.Drawing.Font("Arial", 8.0!, Drawing.FontStyle.Bold) Quote Link to comment Share on other sites More sharing options...
AndreG Posted July 29, 2009 Report Share Posted July 29, 2009 Try changing the font style of the axis section: chart1.AxisX.Sections[0].FontStyle = FontStyle.Bold; Quote Link to comment Share on other sites More sharing options...
ryanlcs Posted July 31, 2009 Author Report Share Posted July 31, 2009 It is not working. Why need to put [0] ? Thanks. 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.