Delphin Posted January 12, 2008 Report Share Posted January 12, 2008 Hi. I am trying to create a bar graph with 3 series. Serie 1: 115, 47, Chart.HiddenSerie 2: Chart.Hidden, Chart.Hidden, 115Serie 3: Chart.Hidden, Chart.Hidden, 34 (Actually I use a DataTable with 3 columns)What I want to do is explain here: http://community.softwarefx.com/forums/p/1016/3290.aspx#3290 But it seems not possible to use Stacked in this way :\ and I cannot use neither 3D mode nor .Clustered attribute. So, I've decided to use Stacked anymore, but the generated chart shows empty bars for Chart.Hidden values.Is it possible to 'remove' this empty space?How to reduce the space between the bars? Possible to set 0 pixel?Thanks. Quote Link to comment Share on other sites More sharing options...
Delphin Posted January 13, 2008 Author Report Share Posted January 13, 2008 Hum... I'm going to try to use only 1 serie and color the two last bars... Ok, it looks better now, but the LegendBox has got only 1 entry... is it possible to enter entry by hand? and how to do to set manually the colors of series inside it and the bars of the first serie? Thanks Quote Link to comment Share on other sites More sharing options...
Delphin Posted January 13, 2008 Author Report Share Posted January 13, 2008 I'd like to get a such graph using 1or 3 series http://picasaweb.google.com/delfwaren/Temp/photo#5154964020828409858http://picasaweb.google.com/delfwaren/Temp/photo#5154964755267817490''>http://picasaweb.google.com/delfwaren/Temp/photo#5154964755267817490' mce_href="http://picasaweb.google.com/delfwaren/Temp/photo#5154964755267817490"> If 3 series are used, I have data like that: S1: 10, 7, 8 hidden, hidden S2: hidden, hidden, hidden, 10 S3: hidden, hidden, hidden, 3 Note: the image uploader popup sucks with Firefox... Quote Link to comment Share on other sites More sharing options...
Frank Posted January 13, 2008 Report Share Posted January 13, 2008 The best way to achieve this is with one series and using per-point attributes: chart.Point[chart.Data.Points-2].Color = Color.Red; chart.Point[chart.Data.Points-1].Color = Color.Green; You can add these colors to the legend box as Custom Items. Quote Link to comment Share on other sites More sharing options...
Delphin Posted January 13, 2008 Author Report Share Posted January 13, 2008 Thanks a lot for this reply. I'll try this method tomorrow (if I can...) and go back to ask more questions or give the source code. Quote Link to comment Share on other sites More sharing options...
Delphin Posted January 14, 2008 Author Report Share Posted January 14, 2008 When I try to access to chart.Points, I get: chart.Points = Count = The name 'm_hashtable' does not exist in the current context ("ChartFX.WinForms.PointAttributesCollection") chart.DataSource = dtData; // Sets the datatable containing 1 column.chart.Points[chart.Data.Points - 2].Color = Color.Red;chart.Points[chart.Data.Points - 1].Color = Color.Green; chart.Data.Points == 4 and chart.Data.Series == 1 Quote Link to comment Share on other sites More sharing options...
Delphin Posted January 14, 2008 Author Report Share Posted January 14, 2008 Hell! It works! How possible? =) Thanks for the help. 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.