.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Stacked Column Chart: Workaround for busted InsertEmptyPoints

Posted By:      Posted Date: August 28, 2010    Points: 0   Category :ASP.Net
I had to struggle with this a bit so I'm gonna share what I figured out. To make a stacked column chart from a SqlDataSource you need to use DataBindCrossTable like this... CHART1.DataBindCrossTable(SqlDataSource1.Select(DataSourceSelectArguments.Empty), "proceso_estado_nombre", "max_fecha_final", "valor", "") Now, each series created needs to be converted to StackedColumn type, which you do like this... For Each series As DataVisualization.Charting.Series In CHART1.Series    series.ChartType = DataVisualization.Charting.SeriesChartType.StackedColumnNext The problem at this point is that the chart wont work if you don't have the same number of points in each series and each set of points should have the same X values. So to fill in the empty points in each series you can use InsertEmptyPoints like this... CHART1.DataManipulator.InsertEmptyPoints(1, DataVisualization.Charting.IntervalType.Months, series.Name.ToString) However, when I did this I got inconsistent results. See below... <Series>    <Series Name="Terminado" Legend="Default" XValueType="Date" ChartType="StackedColumn" ChartArea="ChartArea1" ToolTip="Terminado: #VALY{C0}">      <Points>      

View Complete Post

More Related Resource Links

How do I create a stacked column chart over yrly/mo series/category?




I would like my output to look like this:

2009          2010


|__c__|    | __b__|    

|__b _|   |   a      |

|   a   |   | _____|


where both of the stacked bars represent data for the month of January such that each month would have it's own two years worth of stacked bar data...please help.

Dual values in Column chart Y axis in SSRS 2008

Hi,  Any one pls tell me how to show dual values in Column chart Y axis. Example: Im showing Total Number of clients in the Y axis of column chart My Requirement is In that Y axis column chart also  i want to show differently of Inactive clients from total number of clients. how to do this pls help me. Thanks in advance. TotalnumberOf clients :  1000 InActive Clients : 200 among TotalnumberofClients      

Line Divider i n Column chart in SSRS 2008

Hi,  Any one pls tel me how to do the single line divider in Column chart in SSRS 2008 example: --------- |               | |     20      | ---------- |       100 | |               | -------------------------------   i want to show the above example. Thanks in advance Regards, Abdul2010

Alternate lables are displayed along x axis in chart web part for column chart type

HI I am using Chart webpart of Sharepoint 2010. I am connecting this webpart to my custom list having two coulmn Title  (string) and Count (numeric) and using Column chart type i am displaying data in web part. Each column in chart represents one item in list and displyed along x axis, while y axis represents count. For more than 9 columns in column chart (i.e. more than 9 itmes in list) in chart web part only alternate lables are displyed along x axis. Any help in this will be appreciated.

Combine 100% stacked bar charts onto one chart

Hi All: I have eight questionaires for likert scale (Strongly disagree, disagree, netural, agree and strongly agree). I try to create a 100% stacked bar chart that X axis would be eight questionaires and Y axis is the pecentage.  I couldn't get it work. What I did was to create a single 100% stacked bar chart for each questionaire. That's not the way I want and does anyone know how to create this type chart? Thanks in advance.      

[RS 2008 R2] Advice for Multi-series stacked chart



I need an advice about the layout of a multi-series stacked chart (which I hope is the correct way to realize my report). The data I need to draw has the following structure (aggregations have already been calculated in the database query due to the high amount of data):

Date             Priority    Value
2010-09-19   A             48
2010-09-19   B             50
2010-09-19   C             45
2010-09-19   TA A        11
2010-09-19   TA B        18
2010-09-19   TA C        2
2010-09-19   Total        143

The chart must contain Date on X axis, the Value on Y Axis and stack in the same chart area 7 different graphs according to priority field:
- 4 must be line graph (Priority = A, B, C, Total)
- 3 must be column graph (Priority = TA A, TA B, TA C)

Here follows the way I conceived the chart:
- Date field goes into Category Groups
- Priorit

How to redisplay a category-axis on a column chart after it has been deleted.


Hi All,

This should be simple, but I'm tearing my (limited) hair out trying to solve this.  I have a combined column chart (primary Y axis) and line chart (secondary Y axis) in which the category-axis (X-Axis) was deleted.  Now I want the X-Axis to re-appear.  I can't seem to find an option for re-applying the X-Axis after it has been deleted.

How do I do this?




MS Chart Control ( Does not display all labels in X Axis - Column Chart )



I am facing one problem while using MS Chart Control.. In Column Chart When i am finding minimum no of records chart displays properly.

But When i finding more than 20 records, in X Axis records display randomly(i have 20 records, chart is coming but x axis labels does not appear for all 20.it display 4 or 5 lables only) .. I increased the chart size also. Still it is happeing...

Any one give me idea about to fix this problem..

Thanks in Advance.

3-D column chart - Y - Axis Labels -Instead of Legend



I am having a 3d Column chart in my report but I am not able to show the Labels on the right hand side. as for right hand side it shows only LEGENDs ,not Labels property.

Please have a look at the chart in this like


In this  example

I am able to show the sales figures (Z-axis) and promotion type (X-axis),

but not able to show the date shown in  (Y-axis)

I don't know how to set the labels for Y-axis in this kind of chart.I dont want to show legend as its of no use same color is coming for all Years.

Any help on this.



Stacked Bar chart missing percentage sign



I hope someone can help me. I have used a Stacked bar chart in SSRS 2008. This chart shows the percentage but without the "%" sign.
It's not showen in de datalabel and also not in the axis. I have tryed to format but with a P0 it multipy by 100. Ideas?



Conditionally Hide Percentage Labels on a 100% Stacked Bar Chart SSRS

I have searched for answers on this topic and the only ones I can find are for pie charts.  What I'd like to do is hide the point labels (percentages) on a 100% stacked bar chart when the percentage is below .05%, otherwise the labels are very cluttered and difficult to read.  I have tried to write an expression to do this, however, since the percentage calculation goes on behind the scenes I cannot find a way to refer to this value.  In addition, I am using #.## "%" for my formatting and am wondering if there is a way to remove the % sign when the label is hidden. Any help would be appreciated.  Thanks.

show customized groups in series field in a stacked bar chart



Here I have one doubt, need your help.

I am creating a stacked bar chart in report designer, and I have created the Dataset.

For instance: I drag and drop Count to data field, year to the category field, createdby to the series field. Now I assume that createdby have values: v1,v2,v3,v4,v5,v6. I want to group v1,v2 into Value1, and show in green color; meanwhile group v3,v4,v5 into Value2, show in red color. and do not show v6.

In the final stacked bar chart, I want only Value1 and Value2 shown in series field.

Can you tell me how can I filter v6 and create the two groups? thanks!


Connie Zhu

Workaround to using "Person or Group" field in a "Calculated" column formula?


Apparently, SharePoint does not allow you to insert a "Person or Group" column into a "Calculated" field's formula.

Is there a workaround to adding a "Person or Group" column into a "Calculated" field's formula?

-Maybe a way of coverting the data from the Person or Group column into a text field, and referencing that text field in the formula?

Microsoft mentions only Columns of the following data types can be referenced in a formula: single line of text, number, currency, date and time, choice, yes/no, and calculated.

Show multiple values in stacked bar chart tooltip



I have a stacked bar chart showing my values by geographical region. Within each region I have x-number of DataAreaIDs. I want the user to be able to see the distinct DataAreaIDs via a mouse over on each bar.

I therefore entered this formula in the tooltip option for the regional bar but it only displays #Error: "=join(Fields!DataAreaID.Value,", ")".

I appreciate your help!


Tooltip for GridView Column Headers (ASP.Net)

I just wanted to add auto tooltips for my GridView headers. There are couple of ways but I don't want to use javascript and wanted to use simple 'title' attribute. It took couple of hours to get the working code supporting sortable columns. I thought it will be very useful for others. Here's the code and logic behind it.

Multiple Column Dropdownlist for the ASP.NET DataGrid

Based on my previous control "Multiple Column DropDownList for ASP.NET", I received many emails asking for the same control to be used in the DataGrid for web applications. Here we go.. This control can be used as the regular MS DropDownList in the DataGrid and also as a regular dropdownlist. It has all the properties, like DataTextField, DataValueField, DataSource, SelectedIndex etc. The download file contains the samples both in VB.NET and C#. In this sample, I have used the Northwind database of SQL Server.

Chart Tutorial

The AxisTitle class declares properties that define the common appearance settings of a title which is displayed by a particular axis.

Properties exposed via the AxisTitle class allow you to customize common title attributes, such as:

* the axis title's text (Title.Text),
* the color and font settings of the title's text (TitleBase.TextColor and TitleBase.Font),
* apply antialising (smoothing) to the title's text (TitleBase.Antialiasing),
* the alignment of the axis title (Alignment),
* the visibility of the axis title (TitleBase.Visible).

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend