This is a migrated thread and some comments may be shown as answers.

Changing the color of a bar when negative

1 Answer 23 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
hin
Top achievements
Rank 1
hin asked on 07 Apr 2012, 01:08 AM
I have created charts inside a report using SQLDataSource to bind the data.  I would like my bar graph to show negative entries in red and positive entries in green.

I have tried setting the "ConditionalFormatting" property as in link below but that doesn't do anything. 
http://www.telerik.com/help/reporting/styling-conditional-formatting.html

Also I found this thread, but my data is generated by datasource.  How can I retrieve the ChartSeriesItem from the reportviewer?
http://www.telerik.com/help/reporting/howtoassigncolors.html

Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
    If Not IsPostBack Then
        Dim report As New MyReports.NetIncomeByOffice
        ReportViewer1.Report = report
    End If
End Sub

1 Answer, 1 is accepted

Sort by
0
Hadib Ahmabi
Top achievements
Rank 1
answered on 09 Apr 2012, 08:21 AM
I believe that creating the chart items programmatically is the only way of achieving your requirement. 
Tags
General Discussions
Asked by
hin
Top achievements
Rank 1
Answers by
Hadib Ahmabi
Top achievements
Rank 1
Share this question
or