Showing posts with label chart. Show all posts
Showing posts with label chart. Show all posts

Thursday, March 22, 2012

Combined Chart (One series with Line and One Bar)

Is it possible to create combined charts with the Report Designer Chart?
I want to have one series charted as bar (sales) and the other series as
line (i.e market share).
Want to do it in one chart (not to overlay one chart over the other)
Thanx.Please read this related newsgroup posting:
http://msdn.microsoft.com/newsgroups/default.aspx?dg=microsoft.public.sqlserver.reportingsvcs&mid=c229b25c-b2dc-41ac-923d-decbb253dc6e&sloc=en-us
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"Minas Papageorgiou" <MinasPapageorgiou@.discussions.microsoft.com> wrote in
message news:8AD71606-450E-4E5D-B4DD-12CA9A4A49C5@.microsoft.com...
> Is it possible to create combined charts with the Report Designer Chart?
> I want to have one series charted as bar (sales) and the other series as
> line (i.e market share).
> Want to do it in one chart (not to overlay one chart over the other)
> Thanx.
>

Monday, March 19, 2012

Combine Chart and Matrix on page

I want to combine my matrix and my chart for the current selection on
a single page.
As it is now, I'm stick with all of the results and the chart below
in. I also have parenting on the left side... however... the only
way for my chart to show the selection from the left, I have to put it
on page break. When I do that, my chart gets pushed to the very
last page of the report.
How can I get the chart to stay on the current parent selection
results and reflect the selected change?On Sep 20, 2:04 pm, Bruce Lawrence <BL32...@.gmail.com> wrote:
> I want to combine my matrix and my chart for the current selection on
> a single page.
> As it is now, I'm stick with all of the results and the chart below
> in. I also have parenting on the left side... however... the only
> way for my chart to show the selection from the left, I have to put it
> on page break. When I do that, my chart gets pushed to the very
> last page of the report.
> How can I get the chart to stay on the current parent selection
> results and reflect the selected change?
I'm not sure if I understand you, but you might try including the
chart and matrix control inside a single rectangle. Hope this helps.
Regards,
Enrique Martinez
Sr. Software Consultant

Combination charts issues

I have created a chart to chart a combinational chart including a
stacked column and the continous line charts.
But the problem is this combinational chart nowhere looks like the
Excel combinational chart for the same data as in the reporting
services report. Not sure if this is a problem in the RS charting
engine.
How do I create a stacked column and a continous like chart.
Thanks
KarenHi Karen
So far, I didn't find anything where you can mix charttypes. The only thing
is, you can define a Series to be drawn as a line. You can set that in the
properties of a value on the second tab there's a checkbox for that.
HTH
Luzia
<karenmiddleol@.yahoo.com> schrieb im Newsbeitrag
news:1131399473.731448.325340@.g49g2000cwa.googlegroups.com...
>I have created a chart to chart a combinational chart including a
> stacked column and the continous line charts.
> But the problem is this combinational chart nowhere looks like the
> Excel combinational chart for the same data as in the reporting
> services report. Not sure if this is a problem in the RS charting
> engine.
> How do I create a stacked column and a continous like chart.
> Thanks
> Karen
>|||Hi Luzia
I even dropped setting a combination chart of line and stacked column
instead I set multiple series all line graphs. The charts generated are
nowhere comparable to what I get in Excel not sure what is wrong.
I am frustrated.
Thanks
Karen

Thursday, February 16, 2012

Column Chart Y-axis Values Not Rendering

I'm trying to create a column chart and am having trouble with the y-axis values. I want to chart sales dollars by month, with the dollars on the y-axis.

The datasource is a datatable object with 2 columns, Month & Amount. I dragged the Month column into the category area, and the Amount column into the data fields area

The resulting chart shows a column for each month, but all months have a value of '1' rather than the actual values in the table. For testing, I dropped a table control on the page and the amount values show correctly (=Fields!Amount.Value).

Is the chart showing a count, perhaps? Any help is appreciated.

Maybe the Amount value is a formatted string, rather than a numeric value?

Try the following expression for the data point value in the chart: =Sum(CDbl(Fields!Amount.Value))

-- Robert

|||Thanks, Robert. That was it.

Column Chart Y-axis Values Not Rendering

I'm trying to create a column chart and am having trouble with the y-axis values. I want to chart sales dollars by month, with the dollars on the y-axis.

The datasource is a datatable object with 2 columns, Month & Amount. I dragged the Month column into the category area, and the Amount column into the data fields area

The resulting chart shows a column for each month, but all months have a value of '1' rather than the actual values in the table. For testing, I dropped a table control on the page and the amount values show correctly (=Fields!Amount.Value).

Is the chart showing a count, perhaps? Any help is appreciated.

Maybe the Amount value is a formatted string, rather than a numeric value?

Try the following expression for the data point value in the chart: =Sum(CDbl(Fields!Amount.Value))

-- Robert

|||Thanks, Robert. That was it.

Column chart question

Hi all, I need to add a column chart in my report with static values on x-ais
like -
10 11-30 31-50 51-70 and >90
is there a way I can do that?
Thanks much!
SonalDid you fix this problem?
I also need a way to show custom values on the axis.
Cheers
Adrian

Column Chart Issue in MSRS 2005

Hi,
I have report created with Reporting Service 2000 SP2 designer. This
contains a Column Chart with Simple Column type. I had selected
GraySacle Pallete for my report. I have max 4 columns in my report.
When I deployed the report on MSRS 2000 SP2 Report Server it is showing
correctly. The style of the columns in legend and that appearing in
chart are correct.
When I deploy the same report on MSRS 2005 SP1 Report Server its
showing in-correct. The style of the columns in legend and that
appearing in chart are not matching. For e.g I have a column
representing "Data Unavailable" in legend it shows as "Front
Slash" on reports in the chart this DataUnavailable appears 7 times
(representing week) first time it appears as "Front Slash" 2nd time
"Back Slash" 3rd time "Straight horizontal line", 4th
"Vertical lines" ...and so on all 7 times it appears different.
Is this a bug in 2005. Its working fine in MSRS 2000 SP2
What is a solution for making it consistent on MSRS 2005?
Thanks in advance for any kind of help.
Regards,
ManojHi
Do anyone know the reason for this behaviour?
I tried creating the same report in Reporting Service 2005 SP1
designer. Still same result. GrayScale Pallete shows wrong column graph
other than those shown in legends
Any kind of help in this regards will be very usefull.
Regards,
Manoj
Manoj wrote:
> Hi,
> I have report created with Reporting Service 2000 SP2 designer. This
> contains a Column Chart with Simple Column type. I had selected
> GraySacle Pallete for my report. I have max 4 columns in my report.
> When I deployed the report on MSRS 2000 SP2 Report Server it is showing
> correctly. The style of the columns in legend and that appearing in
> chart are correct.
> When I deploy the same report on MSRS 2005 SP1 Report Server its
> showing in-correct. The style of the columns in legend and that
> appearing in chart are not matching. For e.g I have a column
> representing "Data Unavailable" in legend it shows as "Front
> Slash" on reports in the chart this DataUnavailable appears 7 times
> (representing week) first time it appears as "Front Slash" 2nd time
> "Back Slash" 3rd time "Straight horizontal line", 4th
> "Vertical lines" ...and so on all 7 times it appears different.
> Is this a bug in 2005. Its working fine in MSRS 2000 SP2
> What is a solution for making it consistent on MSRS 2005?
> Thanks in advance for any kind of help.
> Regards,
> Manoj

Column chart bug?

When I am designing a column chart, the chart looks exactly how I want
it to look in Layout view, but then changes in the Preview mode and
when viewed in Report Manager.
Specifically I want to do this:
In the chart Y axis tab, for the scale options:
Minimum .6
Maximum 1.3
Cross 1
The Layout looks correct - when Previewed the chart keeps starting at
the minimum of 0 (instead of the .6 minimum). Since my chart is to
show variance from 1 (below or above), this bug makes it useless (1 is
no longer centered in view - but is up near 1.3).
Any ideas or workarounds?
Thanks!Update: looks like if I use whole numbers, the chart behaves correctly. So -
I guess the question is, how can I use fractions to specify lower and upper
ranges? If I do go with whole numbers (multiply the data by 10) to get the
chart to look OK, can I change the displayed Y axis labels (by dividing them
by 10)?
"coldfact" wrote:
> When I am designing a column chart, the chart looks exactly how I want
> it to look in Layout view, but then changes in the Preview mode and
> when viewed in Report Manager.
> Specifically I want to do this:
> In the chart Y axis tab, for the scale options:
> Minimum .6
> Maximum 1.3
> Cross 1
> The Layout looks correct - when Previewed the chart keeps starting at
> the minimum of 0 (instead of the .6 minimum). Since my chart is to
> show variance from 1 (below or above), this bug makes it useless (1 is
> no longer centered in view - but is up near 1.3).
> Any ideas or workarounds?
> Thanks!
>|||Try this:
Minimum 0.6
Maximum 1.3
CrossAt 1.0
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"coldfact" <coldfact@.discussions.microsoft.com> wrote in message
news:E16862E2-6EBB-4422-A438-DD7EE8673F3F@.microsoft.com...
> Update: looks like if I use whole numbers, the chart behaves correctly.
So -
> I guess the question is, how can I use fractions to specify lower and
upper
> ranges? If I do go with whole numbers (multiply the data by 10) to get the
> chart to look OK, can I change the displayed Y axis labels (by dividing
them
> by 10)?
> "coldfact" wrote:
> > When I am designing a column chart, the chart looks exactly how I want
> > it to look in Layout view, but then changes in the Preview mode and
> > when viewed in Report Manager.
> >
> > Specifically I want to do this:
> > In the chart Y axis tab, for the scale options:
> > Minimum .6
> > Maximum 1.3
> > Cross 1
> >
> > The Layout looks correct - when Previewed the chart keeps starting at
> > the minimum of 0 (instead of the .6 minimum). Since my chart is to
> > show variance from 1 (below or above), this bug makes it useless (1 is
> > no longer centered in view - but is up near 1.3).
> >
> > Any ideas or workarounds?
> > Thanks!
> >|||Much thanks! It is the 1.0 (vs 1) that makes the difference...
:)
"Robert Bruckner [MSFT]" wrote:
> Try this:
> Minimum 0.6
> Maximum 1.3
> CrossAt 1.0
> --
> This posting is provided "AS IS" with no warranties, and confers no rights.
> "coldfact" <coldfact@.discussions.microsoft.com> wrote in message
> news:E16862E2-6EBB-4422-A438-DD7EE8673F3F@.microsoft.com...
> > Update: looks like if I use whole numbers, the chart behaves correctly.
> So -
> > I guess the question is, how can I use fractions to specify lower and
> upper
> > ranges? If I do go with whole numbers (multiply the data by 10) to get the
> > chart to look OK, can I change the displayed Y axis labels (by dividing
> them
> > by 10)?
> >
> > "coldfact" wrote:
> >
> > > When I am designing a column chart, the chart looks exactly how I want
> > > it to look in Layout view, but then changes in the Preview mode and
> > > when viewed in Report Manager.
> > >
> > > Specifically I want to do this:
> > > In the chart Y axis tab, for the scale options:
> > > Minimum .6
> > > Maximum 1.3
> > > Cross 1
> > >
> > > The Layout looks correct - when Previewed the chart keeps starting at
> > > the minimum of 0 (instead of the .6 minimum). Since my chart is to
> > > show variance from 1 (below or above), this bug makes it useless (1 is
> > > no longer centered in view - but is up near 1.3).
> > >
> > > Any ideas or workarounds?
> > > Thanks!
> > >
>
>|||Explanation: If at least one value of the axis settings is an integer, we
use a mode of the chart control to generate "nice" integer labels and not
default float labels like 0.05, 1.05, 2.05, etc. (which are determined based
on the minimum and maximum data point values of the chart).
If you really want float labels, make sure to either not specify values for
certain axis settings or specify them as float values rather than integer
values.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"coldfact" <coldfact@.discussions.microsoft.com> wrote in message
news:A3D8D209-6C1E-4930-B948-202466FDF30D@.microsoft.com...
> Much thanks! It is the 1.0 (vs 1) that makes the difference...
> :)
> "Robert Bruckner [MSFT]" wrote:
> > Try this:
> > Minimum 0.6
> > Maximum 1.3
> > CrossAt 1.0
> >
> > --
> > This posting is provided "AS IS" with no warranties, and confers no
rights.
> >
> > "coldfact" <coldfact@.discussions.microsoft.com> wrote in message
> > news:E16862E2-6EBB-4422-A438-DD7EE8673F3F@.microsoft.com...
> > > Update: looks like if I use whole numbers, the chart behaves
correctly.
> > So -
> > > I guess the question is, how can I use fractions to specify lower and
> > upper
> > > ranges? If I do go with whole numbers (multiply the data by 10) to get
the
> > > chart to look OK, can I change the displayed Y axis labels (by
dividing
> > them
> > > by 10)?
> > >
> > > "coldfact" wrote:
> > >
> > > > When I am designing a column chart, the chart looks exactly how I
want
> > > > it to look in Layout view, but then changes in the Preview mode and
> > > > when viewed in Report Manager.
> > > >
> > > > Specifically I want to do this:
> > > > In the chart Y axis tab, for the scale options:
> > > > Minimum .6
> > > > Maximum 1.3
> > > > Cross 1
> > > >
> > > > The Layout looks correct - when Previewed the chart keeps starting
at
> > > > the minimum of 0 (instead of the .6 minimum). Since my chart is to
> > > > show variance from 1 (below or above), this bug makes it useless (1
is
> > > > no longer centered in view - but is up near 1.3).
> > > >
> > > > Any ideas or workarounds?
> > > > Thanks!
> > > >
> >
> >
> >

Column Chart Bar Borders

Can I add borders to my bars in the column chart? My bars don't appear to have any border, and I can't see a place to set one. I am using SSRS Express.

Thanks!

Michael

1)Double click the bar chart
2)Double click the chart value in the "Drop data fields here"
3)Select the Appearance tab
4)Click on the Series Style at the bottom of the dialog box
5)Choose your style and your color for "Border and Line"

6)Click OK, Click OK

|||

Ah, so much better. Thanks! I knew I had seen the option before, but couldn't find it. I HAD right clicked on the drop data fields items for the other two axes, but not that VALUE axis. Grrr... Thanks for the help!

Michael

Column Chart

Hi,
Is it possible to display the Category Fields diagonally ?
ThanksSorry, this is not supported.
-- Robert
This posting is provided "AS IS" with no warranties, and confers no rights.
"collie" <collie@.discussions.microsoft.com> wrote in message
news:2076A937-2128-4AF9-B77C-0D6ED687C7F2@.microsoft.com...
> Hi,
> Is it possible to display the Category Fields diagonally ?
> Thanks|||Thanks for the reply.
"Robert Bruckner [MSFT]" wrote:
> Sorry, this is not supported.
> -- Robert
> This posting is provided "AS IS" with no warranties, and confers no rights.
> "collie" <collie@.discussions.microsoft.com> wrote in message
> news:2076A937-2128-4AF9-B77C-0D6ED687C7F2@.microsoft.com...
> > Hi,
> >
> > Is it possible to display the Category Fields diagonally ?
> >
> > Thanks
>
>

Tuesday, February 14, 2012

Colouring the chart plot area based on x-axis scale

Hi,

I have a report based on a line chart.

The values on X-axis are scaled from -100 to +100. I want to colour the band from -100 to 0 with red colour and that from 0 to +100 in green colour, and i want to provide legend for these bands/sections. How can i do this?

This doesn't look like a tough thing to do but i can't find a way to do it within the chart properties.

Basically i would like to divide the chart (plot area) into multiple vertical bars, each having a different colour. The colour is determined by the range that vertical bar covers on the x-axis

Thanks a lot!

Simranjeev

To color the bars on the chart, go to Chart Properties -> Data -> Edit button in the Values section -> Appearance Tab -> click the Series Style button -> Fill tab

You will have to enter an expression in the color property for the bar to be one solid color. The expression should look something like:
IIF(Fields!XAxisField.Value < 0, "Red", "Green")

You can do this if the axis value is a number or date. You may have to nest a couple of IIF statements if there are a lot of sections that you want to use. I don't think you can use the legend provided by reporting services for what you want it to accomplish since it is based on the series fields. You can create your own legend with a few lines, textboxes, and property changes though.

Colouring the chart plot area based on x-axis scale

Hi,

I have a report based on a line chart.

The values on X-axis are scaled from -100 to +100. I want to colour the band from -100 to 0 with red colour and that from 0 to +100 in green colour, and i want to provide legend for these bands/sections. How can i do this?

A prompt response would be really appreciated

Thanks a lot!!

Simranjeev

Hi!

This is a little urgent so i would really appreciate some response.

This doesn't look like a tough thing to do but i can't find a way to do it within the chart properties.

Basically i would like to divide the chart (plot area) into multiple vertical bars, each having a different colour. The colour is determined by the range that vertical bar covers on the x-axis

Thanks!

Simranjeev

Colour of the series in legend

I have few chart based reports where I am showing different costs in series. I want to fix the colour of each type of cost so that I can maintain the same colour for each cost in different reports.

Is it possible? If yes, then please let me know.

Thanks in advance!!!

Check out my sample report on Brian Welcker's blog: http://blogs.msdn.com/bwelcker/archive/2005/05/20/420349.aspx

-- Robert

Colors in Charts

Hi Ng,
I was wondering if there is a way to change the colors of the bars in a
chart. Or the colors of the pieces in a cake chart?
Thank in Advance
G. SchmelzerYou can control this from Chart properties dialog -> Data tab -> Values ->
Edit... -> Edit Chart Value dialog -> Appearance tab -> Series Style...
button -> Fill tab.
--
Ravi Mumulla (Microsoft)
SQL Server Reporting Services
This posting is provided "AS IS" with no warranties, and confers no rights.
"Georg Schmelzer" <asdf@.adsf.de> wrote in message
news:e9XCdDGeEHA.3412@.TK2MSFTNGP11.phx.gbl...
> Hi Ng,
> I was wondering if there is a way to change the colors of the bars in a
> chart. Or the colors of the pieces in a cake chart?
> Thank in Advance
> G. Schmelzer
>|||Note: this will require SP1 installed on clients (report designer) and
report server.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"Ravi Mumulla (Microsoft)" <ravimu@.online.microsoft.com> wrote in message
news:%23%23UP63JeEHA.1692@.tk2msftngp13.phx.gbl...
> You can control this from Chart properties dialog -> Data tab -> Values ->
> Edit... -> Edit Chart Value dialog -> Appearance tab -> Series Style...
> button -> Fill tab.
> --
> Ravi Mumulla (Microsoft)
> SQL Server Reporting Services
> This posting is provided "AS IS" with no warranties, and confers no
rights.
> "Georg Schmelzer" <asdf@.adsf.de> wrote in message
> news:e9XCdDGeEHA.3412@.TK2MSFTNGP11.phx.gbl...
> > Hi Ng,
> >
> > I was wondering if there is a way to change the colors of the bars in a
> > chart. Or the colors of the pieces in a cake chart?
> >
> > Thank in Advance
> >
> > G. Schmelzer
> >
> >
>|||Thank You.
The specified color on the "fill tab" is used for all chart items (f.e. all
bars, cake pieces, etc...). Let's say I want to change the color of bar1 to
red, bar2 to green and bar3 to pink. I would be like a user designed
"palette". But I found no information wether or how I can do this. Any Idea?
Thanks in advance
G. Schmelzer
"Robert Bruckner [MSFT]" <robruc@.online.microsoft.com> schrieb im
Newsbeitrag news:eqd%23A6KeEHA.592@.TK2MSFTNGP11.phx.gbl...
> Note: this will require SP1 installed on clients (report designer) and
> report server.
> --
> This posting is provided "AS IS" with no warranties, and confers no
rights.
>
> "Ravi Mumulla (Microsoft)" <ravimu@.online.microsoft.com> wrote in message
> news:%23%23UP63JeEHA.1692@.tk2msftngp13.phx.gbl...
> > You can control this from Chart properties dialog -> Data tab ->
Values ->
> > Edit... -> Edit Chart Value dialog -> Appearance tab -> Series Style...
> > button -> Fill tab.
> >
> > --
> > Ravi Mumulla (Microsoft)
> > SQL Server Reporting Services
> >
> > This posting is provided "AS IS" with no warranties, and confers no
> rights.
> > "Georg Schmelzer" <asdf@.adsf.de> wrote in message
> > news:e9XCdDGeEHA.3412@.TK2MSFTNGP11.phx.gbl...
> > > Hi Ng,
> > >
> > > I was wondering if there is a way to change the colors of the bars in
a
> > > chart. Or the colors of the pieces in a cake chart?
> > >
> > > Thank in Advance
> > >
> > > G. Schmelzer
> > >
> > >
> >
> >
>|||Write an expression for Fill Color. You could use Choose() function:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vblr7/html/vafctchoose.asp.
--
Ravi Mumulla (Microsoft)
SQL Server Reporting Services
This posting is provided "AS IS" with no warranties, and confers no rights.
"Georg Schmelzer" <asdf@.adsf.de> wrote in message
news:%239AdRUheEHA.3412@.TK2MSFTNGP11.phx.gbl...
> Thank You.
>
> The specified color on the "fill tab" is used for all chart items (f.e.
all
> bars, cake pieces, etc...). Let's say I want to change the color of bar1
to
> red, bar2 to green and bar3 to pink. I would be like a user designed
> "palette". But I found no information wether or how I can do this. Any
Idea?
> Thanks in advance
> G. Schmelzer
>
> "Robert Bruckner [MSFT]" <robruc@.online.microsoft.com> schrieb im
> Newsbeitrag news:eqd%23A6KeEHA.592@.TK2MSFTNGP11.phx.gbl...
> > Note: this will require SP1 installed on clients (report designer) and
> > report server.
> >
> > --
> > This posting is provided "AS IS" with no warranties, and confers no
> rights.
> >
> >
> > "Ravi Mumulla (Microsoft)" <ravimu@.online.microsoft.com> wrote in
message
> > news:%23%23UP63JeEHA.1692@.tk2msftngp13.phx.gbl...
> > > You can control this from Chart properties dialog -> Data tab ->
> Values ->
> > > Edit... -> Edit Chart Value dialog -> Appearance tab -> Series
Style...
> > > button -> Fill tab.
> > >
> > > --
> > > Ravi Mumulla (Microsoft)
> > > SQL Server Reporting Services
> > >
> > > This posting is provided "AS IS" with no warranties, and confers no
> > rights.
> > > "Georg Schmelzer" <asdf@.adsf.de> wrote in message
> > > news:e9XCdDGeEHA.3412@.TK2MSFTNGP11.phx.gbl...
> > > > Hi Ng,
> > > >
> > > > I was wondering if there is a way to change the colors of the bars
in
> a
> > > > chart. Or the colors of the pieces in a cake chart?
> > > >
> > > > Thank in Advance
> > > >
> > > > G. Schmelzer
> > > >
> > > >
> > >
> > >
> >
> >
>|||It worked out fine.
Thanks a lot to you guys!!!
"Ravi Mumulla (Microsoft)" <ravimu@.online.microsoft.com> schrieb im
Newsbeitrag news:%23GTGGNoeEHA.2396@.TK2MSFTNGP11.phx.gbl...
> Write an expression for Fill Color. You could use Choose() function:
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vblr7/html/vafctchoose.asp.
> --
> Ravi Mumulla (Microsoft)
> SQL Server Reporting Services
> This posting is provided "AS IS" with no warranties, and confers no
rights.
> "Georg Schmelzer" <asdf@.adsf.de> wrote in message
> news:%239AdRUheEHA.3412@.TK2MSFTNGP11.phx.gbl...
> > Thank You.
> >
> >
> > The specified color on the "fill tab" is used for all chart items (f.e.
> all
> > bars, cake pieces, etc...). Let's say I want to change the color of bar1
> to
> > red, bar2 to green and bar3 to pink. I would be like a user designed
> > "palette". But I found no information wether or how I can do this. Any
> Idea?
> >
> > Thanks in advance
> >
> > G. Schmelzer
> >
> >
> > "Robert Bruckner [MSFT]" <robruc@.online.microsoft.com> schrieb im
> > Newsbeitrag news:eqd%23A6KeEHA.592@.TK2MSFTNGP11.phx.gbl...
> > > Note: this will require SP1 installed on clients (report designer) and
> > > report server.
> > >
> > > --
> > > This posting is provided "AS IS" with no warranties, and confers no
> > rights.
> > >
> > >
> > > "Ravi Mumulla (Microsoft)" <ravimu@.online.microsoft.com> wrote in
> message
> > > news:%23%23UP63JeEHA.1692@.tk2msftngp13.phx.gbl...
> > > > You can control this from Chart properties dialog -> Data tab ->
> > Values ->
> > > > Edit... -> Edit Chart Value dialog -> Appearance tab -> Series
> Style...
> > > > button -> Fill tab.
> > > >
> > > > --
> > > > Ravi Mumulla (Microsoft)
> > > > SQL Server Reporting Services
> > > >
> > > > This posting is provided "AS IS" with no warranties, and confers no
> > > rights.
> > > > "Georg Schmelzer" <asdf@.adsf.de> wrote in message
> > > > news:e9XCdDGeEHA.3412@.TK2MSFTNGP11.phx.gbl...
> > > > > Hi Ng,
> > > > >
> > > > > I was wondering if there is a way to change the colors of the bars
> in
> > a
> > > > > chart. Or the colors of the pieces in a cake chart?
> > > > >
> > > > > Thank in Advance
> > > > >
> > > > > G. Schmelzer
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>|||Hi Ng,
I was wondering if there is a way to change the orientation of headings on
X-axis of a chart from horizontal to vertical?
Please reply on this site or at the foll: email id : sp_kamath@.hotmail.com
Thank in Advance
SPK|||In RS 2000 the orientation of x-axis labels is determined automatically
based on the amount of space available. If labels cannot be drawn
horizontally in one line, and also not in two lines, they will be rotated
by -90 degrees.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"SanjayK" <SanjayK@.discussions.microsoft.com> wrote in message
news:F876F44C-CEA6-4D90-9A73-A9C6721A563D@.microsoft.com...
> Hi Ng,
> I was wondering if there is a way to change the orientation of headings
on
> X-axis of a chart from horizontal to vertical?
> Please reply on this site or at the foll: email id : sp_kamath@.hotmail.com
> Thank in Advance
> SPK
>|||Hi Ng,
I was wondering if there is a way to display headings on Z axis of graph
since I am not getting any headings on this axis.
Please reply to this post or mail me at sp_kamath@.hotmail.com
Thank in Advance
Sanjay K|||Headings on the Z-axis are not available. You may want to look into using
the legend to provide a description for the series along the Z-axis.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"SanjayK" <SanjayK@.discussions.microsoft.com> wrote in message
news:596FB267-23AE-4D98-A399-B5C76AF50000@.microsoft.com...
> Hi Ng,
> I was wondering if there is a way to display headings on Z axis of graph
> since I am not getting any headings on this axis.
> Please reply to this post or mail me at sp_kamath@.hotmail.com
> Thank in Advance
> Sanjay K
>|||Hi,
Even i want different bars to have customized colors but i am unable to set
it. Ravi has asked to use choose function.But i am unable to use it. please
let me know how to use it. You can mail me at kiran_nandedkar@.rediffmail.com
or reply at same post
Thanks in advance
Kiran
"Georg Schmelzer" wrote:
> It worked out fine.
> Thanks a lot to you guys!!!
>
> "Ravi Mumulla (Microsoft)" <ravimu@.online.microsoft.com> schrieb im
> Newsbeitrag news:%23GTGGNoeEHA.2396@.TK2MSFTNGP11.phx.gbl...
> > Write an expression for Fill Color. You could use Choose() function:
> >
> http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vblr7/html/vafctchoose.asp.
> >
> > --
> > Ravi Mumulla (Microsoft)
> > SQL Server Reporting Services
> >
> > This posting is provided "AS IS" with no warranties, and confers no
> rights.
> > "Georg Schmelzer" <asdf@.adsf.de> wrote in message
> > news:%239AdRUheEHA.3412@.TK2MSFTNGP11.phx.gbl...
> > > Thank You.
> > >
> > >
> > > The specified color on the "fill tab" is used for all chart items (f.e.
> > all
> > > bars, cake pieces, etc...). Let's say I want to change the color of bar1
> > to
> > > red, bar2 to green and bar3 to pink. I would be like a user designed
> > > "palette". But I found no information wether or how I can do this. Any
> > Idea?
> > >
> > > Thanks in advance
> > >
> > > G. Schmelzer
> > >
> > >
> > > "Robert Bruckner [MSFT]" <robruc@.online.microsoft.com> schrieb im
> > > Newsbeitrag news:eqd%23A6KeEHA.592@.TK2MSFTNGP11.phx.gbl...
> > > > Note: this will require SP1 installed on clients (report designer) and
> > > > report server.
> > > >
> > > > --
> > > > This posting is provided "AS IS" with no warranties, and confers no
> > > rights.
> > > >
> > > >
> > > > "Ravi Mumulla (Microsoft)" <ravimu@.online.microsoft.com> wrote in
> > message
> > > > news:%23%23UP63JeEHA.1692@.tk2msftngp13.phx.gbl...
> > > > > You can control this from Chart properties dialog -> Data tab ->
> > > Values ->
> > > > > Edit... -> Edit Chart Value dialog -> Appearance tab -> Series
> > Style...
> > > > > button -> Fill tab.
> > > > >
> > > > > --
> > > > > Ravi Mumulla (Microsoft)
> > > > > SQL Server Reporting Services
> > > > >
> > > > > This posting is provided "AS IS" with no warranties, and confers no
> > > > rights.
> > > > > "Georg Schmelzer" <asdf@.adsf.de> wrote in message
> > > > > news:e9XCdDGeEHA.3412@.TK2MSFTNGP11.phx.gbl...
> > > > > > Hi Ng,
> > > > > >
> > > > > > I was wondering if there is a way to change the colors of the bars
> > in
> > > a
> > > > > > chart. Or the colors of the pieces in a cake chart?
> > > > > >
> > > > > > Thank in Advance
> > > > > >
> > > > > > G. Schmelzer
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>

Colors for Line Chart

Hi,
I have created a line chart with 3 different datafields. I want them to
have the colors yellow for the first, red for the second and blue for the
third. Is there anyway we can manipulate the colors on the chart? If there
is, can you kindly tell me how or point me in the direction of how to do
that?
Thank You,
RickyYou will need to have SP1 of RS 2000 installed on the server and designer
machines. In particular, read the following section of the SP1 readme file
about using colors in charts:
http://download.microsoft.com/download/7/f/b/7fb1a251-13ad-404c-a034-10d79ddaa510/SP1Readme_EN.htm#_chart_enhancements
-- Robert
This posting is provided "AS IS" with no warranties, and confers no rights.
"Ricky" <kmeas1@.gmail.com> wrote in message
news:Oj5gfVHPFHA.3380@.TK2MSFTNGP15.phx.gbl...
> Hi,
> I have created a line chart with 3 different datafields. I want them to
> have the colors yellow for the first, red for the second and blue for the
> third. Is there anyway we can manipulate the colors on the chart? If
> there is, can you kindly tell me how or point me in the direction of how
> to do that?
> Thank You,
> Ricky
>

Sunday, February 12, 2012

Color of pens in Line chart ?

Hi,
how can I change the line color in line charts ?
RitchieTry:
Chart Properties > Tab Data > Edit Value > Tab Appearance
"Ritchie" <Ritchie@.discussions.microsoft.com> escribió en el mensaje
news:898D80BA-E315-4A1E-9D39-2463CBDCE482@.microsoft.com...
> Hi,
> how can I change the line color in line charts ?
> Ritchie|||Hi Mónica,
does this menue item also exists on a .NET 2003 Version ?
I do not saw any configured of the color for each pen ?
Ritchie
"Mónica" wrote:
> Try:
> Chart Properties > Tab Data > Edit Value > Tab Appearance
>
>
> "Ritchie" <Ritchie@.discussions.microsoft.com> escribió en el mensaje
> news:898D80BA-E315-4A1E-9D39-2463CBDCE482@.microsoft.com...
> > Hi,
> >
> > how can I change the line color in line charts ?
> >
> > Ritchie
>
>|||Ummm, I don´t know. I´m using .NET 2005.
I´m sorry I can´t help you :-(
"Ritchie" <Ritchie@.discussions.microsoft.com> escribió en el mensaje
news:04F4DEFE-A23D-420F-A30F-4EAB93C52307@.microsoft.com...
> Hi Mónica,
> does this menue item also exists on a .NET 2003 Version ?
> I do not saw any configured of the color for each pen ?
> Ritchie
> "Mónica" wrote:
>> Try:
>> Chart Properties > Tab Data > Edit Value > Tab Appearance
>>
>>
>> "Ritchie" <Ritchie@.discussions.microsoft.com> escribió en el mensaje
>> news:898D80BA-E315-4A1E-9D39-2463CBDCE482@.microsoft.com...
>> > Hi,
>> >
>> > how can I change the line color in line charts ?
>> >
>> > Ritchie
>>|||Thanks for your help anyway..
Ritchie
"Mónica" wrote:
> Ummm, I don´t know. I´m using .NET 2005.
> I´m sorry I can´t help you :-(
>
> "Ritchie" <Ritchie@.discussions.microsoft.com> escribió en el mensaje
> news:04F4DEFE-A23D-420F-A30F-4EAB93C52307@.microsoft.com...
> > Hi Mónica,
> >
> > does this menue item also exists on a .NET 2003 Version ?
> >
> > I do not saw any configured of the color for each pen ?
> >
> > Ritchie
> >
> > "Mónica" wrote:
> >
> >> Try:
> >>
> >> Chart Properties > Tab Data > Edit Value > Tab Appearance
> >>
> >>
> >>
> >>
> >> "Ritchie" <Ritchie@.discussions.microsoft.com> escribió en el mensaje
> >> news:898D80BA-E315-4A1E-9D39-2463CBDCE482@.microsoft.com...
> >> > Hi,
> >> >
> >> > how can I change the line color in line charts ?
> >> >
> >> > Ritchie
> >>
> >>
> >>
>
>

Color inconsistent on each slice of Pie

Hello all!!
I have created a pie chart that is embedded in a matrix report, therefore
creating a new pie for every row. The problem I am having is the pie slice
for the same series is changing each time there is a new pie. For example,
in the first pie Cars may be designated as green but in the second pie it may
be red. I would like the colors to be consistent; all cars are represented
as green slices. Oh and if there are no cars don't use the color green for
another slice.
I think this can be done using a nested expression but I am unsure how to
write it...I either need an example of an expression that can handle
multiple slices or another way to handle the issue.
Thanks,
AnthonyI suggest to follow the approach discussed in this blog article:
http://blogs.msdn.com/bwelcker/archive/2005/05/20/420349.aspx
You don't need the part about the custom legend, but you should take a close
look at the custom color part of the sample. You can modify the code so that
instead of having the hashtable approach to apply unique colors for
categories, you replace it with some IF statement to explicitly control
colors.
A trivial RDL sample with two charts using different filters but sharing the
same colors for categories is copied to the bottom of this posting.
-- Robert
This posting is provided "AS IS" with no warranties, and confers no rights.
"anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
news:69E297FD-F5C7-44D4-9463-5E4871B1CEAB@.microsoft.com...
> Hello all!!
> I have created a pie chart that is embedded in a matrix report, therefore
> creating a new pie for every row. The problem I am having is the pie
> slice
> for the same series is changing each time there is a new pie. For
> example,
> in the first pie Cars may be designated as green but in the second pie it
> may
> be red. I would like the colors to be consistent; all cars are
> represented
> as green slices. Oh and if there are no cars don't use the color green
> for
> another slice.
> I think this can be done using a nested expression but I am unsure how to
> write it...I either need an example of an expression that can handle
> multiple slices or another way to handle the issue.
> Thanks,
> Anthony
============================================
<?xml version="1.0" encoding="utf-8"?>
<Report
xmlns="http://schemas.microsoft.com/sqlserver/reporting/2003/10/reportdefinition"
xmlns:rd="">http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
<RightMargin>1in</RightMargin>
<Author>Robert M. Bruckner</Author>
<Body>
<ReportItems>
<Chart Name="chart2">
<ThreeDProperties>
<Rotation>30</Rotation>
<Inclination>30</Inclination>
<Shading>Simple</Shading>
<WallThickness>50</WallThickness>
</ThreeDProperties>
<ZIndex>1</ZIndex>
<Style>
<BackgroundColor>White</BackgroundColor>
</Style>
<Legend>
<Visible>true</Visible>
<Style>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
<Position>RightCenter</Position>
</Legend>
<Palette>Default</Palette>
<ChartData>
<ChartSeries>
<DataPoints>
<DataPoint>
<DataValues>
<DataValue>
<Value>=Sum(Fields!UnitsInStock.Value)</Value>
</DataValue>
</DataValues>
<DataLabel />
<Style>
<BackgroundColor>=Code.GetColor(Fields!CategoryName.Value)</BackgroundColor>
</Style>
<Marker>
<Size>6pt</Size>
</Marker>
</DataPoint>
</DataPoints>
</ChartSeries>
</ChartData>
<CategoryAxis>
<Axis>
<Title />
<MajorGridLines>
<Style>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
</MajorGridLines>
<MinorGridLines>
<Style>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
</MinorGridLines>
<Min>0</Min>
</Axis>
</CategoryAxis>
<DataSetName>DataSet1</DataSetName>
<PointWidth>0</PointWidth>
<Type>Bar</Type>
<Top>3.125in</Top>
<Title>
<Caption>UK</Caption>
</Title>
<Width>6in</Width>
<SeriesGroupings>
<SeriesGrouping>
<DynamicSeries>
<Grouping Name="chart2_SeriesGroup1">
<GroupExpressions>
<GroupExpression>=Fields!CategoryName.Value</GroupExpression>
</GroupExpressions>
</Grouping>
<Sorting>
<SortBy>
<SortExpression>=Fields!CategoryName.Value</SortExpression>
<Direction>Ascending</Direction>
</SortBy>
</Sorting>
<Label>=Fields!CategoryName.Value</Label>
</DynamicSeries>
</SeriesGrouping>
</SeriesGroupings>
<Subtype>Plain</Subtype>
<PlotArea>
<Style>
<BackgroundColor>LightGrey</BackgroundColor>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
</PlotArea>
<Filters>
<Filter>
<FilterExpression>=Fields!Country.Value</FilterExpression>
<Operator>Equal</Operator>
<FilterValues>
<FilterValue>UK</FilterValue>
</FilterValues>
</Filter>
</Filters>
<Left>0.125in</Left>
<ValueAxis>
<Axis>
<Title />
<MajorGridLines>
<ShowGridLines>true</ShowGridLines>
<Style>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
</MajorGridLines>
<MinorGridLines>
<Style>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
</MinorGridLines>
<MajorTickMarks>Outside</MajorTickMarks>
<Min>0</Min>
<Margin>true</Margin>
<Visible>true</Visible>
<Scalar>true</Scalar>
</Axis>
</ValueAxis>
</Chart>
<Chart Name="chart1">
<ThreeDProperties>
<Rotation>30</Rotation>
<Inclination>30</Inclination>
<Shading>Simple</Shading>
<WallThickness>50</WallThickness>
</ThreeDProperties>
<Style>
<BackgroundColor>White</BackgroundColor>
</Style>
<Legend>
<Visible>true</Visible>
<Style>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
<Position>RightCenter</Position>
</Legend>
<Palette>Default</Palette>
<ChartData>
<ChartSeries>
<DataPoints>
<DataPoint>
<DataValues>
<DataValue>
<Value>=Sum(Fields!UnitsInStock.Value)</Value>
</DataValue>
</DataValues>
<DataLabel />
<Style>
<BackgroundColor>=Code.GetColor(Fields!CategoryName.Value)</BackgroundColor>
</Style>
<Marker>
<Size>6pt</Size>
</Marker>
</DataPoint>
</DataPoints>
</ChartSeries>
</ChartData>
<CategoryAxis>
<Axis>
<Title />
<MajorGridLines>
<Style>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
</MajorGridLines>
<MinorGridLines>
<Style>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
</MinorGridLines>
<Min>0</Min>
</Axis>
</CategoryAxis>
<DataSetName>DataSet1</DataSetName>
<PointWidth>0</PointWidth>
<Type>Bar</Type>
<Top>0.25in</Top>
<Title>
<Caption>USA</Caption>
</Title>
<Width>6in</Width>
<Height>2.5in</Height>
<SeriesGroupings>
<SeriesGrouping>
<DynamicSeries>
<Grouping Name="chart1_SeriesGroup1">
<GroupExpressions>
<GroupExpression>=Fields!CategoryName.Value</GroupExpression>
</GroupExpressions>
</Grouping>
<Sorting>
<SortBy>
<SortExpression>=Fields!CategoryName.Value</SortExpression>
<Direction>Ascending</Direction>
</SortBy>
</Sorting>
<Label>=Fields!CategoryName.Value</Label>
</DynamicSeries>
</SeriesGrouping>
</SeriesGroupings>
<Subtype>Plain</Subtype>
<PlotArea>
<Style>
<BackgroundColor>LightGrey</BackgroundColor>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
</PlotArea>
<Filters>
<Filter>
<FilterExpression>=Fields!Country.Value</FilterExpression>
<Operator>Equal</Operator>
<FilterValues>
<FilterValue>USA</FilterValue>
</FilterValues>
</Filter>
</Filters>
<Left>0.125in</Left>
<ValueAxis>
<Axis>
<Title />
<MajorGridLines>
<ShowGridLines>true</ShowGridLines>
<Style>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
</MajorGridLines>
<MinorGridLines>
<Style>
<BorderStyle>
<Default>Solid</Default>
</BorderStyle>
</Style>
</MinorGridLines>
<MajorTickMarks>Outside</MajorTickMarks>
<Min>0</Min>
<Margin>true</Margin>
<Visible>true</Visible>
<Scalar>true</Scalar>
</Axis>
</ValueAxis>
</Chart>
</ReportItems>
<Style />
<Height>5.625in</Height>
</Body>
<TopMargin>1in</TopMargin>
<DataSources>
<DataSource Name="Northwind">
<rd:DataSourceID>f646058b-4784-494d-a09d-27fde13a5679</rd:DataSourceID>
<ConnectionProperties>
<DataProvider>SQL</DataProvider>
<ConnectString>data source=(local);initial
catalog=Northwind</ConnectString>
<IntegratedSecurity>true</IntegratedSecurity>
</ConnectionProperties>
</DataSource>
</DataSources>
<Code> Private colorPalette As String() = {"Green", "Blue", "Red",
"Orange", "Aqua", "Teal", "Gold", "RoyalBlue", "#A59D93", "#B8341B",
"#352F26", "#F1E7D6", "#E16C56", "#CFBA9B"}
Private count As Integer = 0
Private mapping As New System.Collections.Hashtable()
Public Function GetColor(ByVal groupingValue As String) As String
If mapping.ContainsKey(groupingValue) Then
Return mapping(groupingValue)
End If
Dim c As String = colorPalette(count Mod colorPalette.Length)
count = count + 1
mapping.Add(groupingValue, c)
Return c
End Function
</Code>
<Width>6.5in</Width>
<DataSets>
<DataSet Name="DataSet1">
<Fields>
<Field Name="ProductID">
<DataField>ProductID</DataField>
<rd:TypeName>System.Int32</rd:TypeName>
</Field>
<Field Name="ProductName">
<DataField>ProductName</DataField>
<rd:TypeName>System.String</rd:TypeName>
</Field>
<Field Name="SupplierID">
<DataField>SupplierID</DataField>
<rd:TypeName>System.Int32</rd:TypeName>
</Field>
<Field Name="CategoryID">
<DataField>CategoryID</DataField>
<rd:TypeName>System.Int32</rd:TypeName>
</Field>
<Field Name="QuantityPerUnit">
<DataField>QuantityPerUnit</DataField>
<rd:TypeName>System.String</rd:TypeName>
</Field>
<Field Name="UnitPrice">
<DataField>UnitPrice</DataField>
<rd:TypeName>System.Decimal</rd:TypeName>
</Field>
<Field Name="UnitsInStock">
<DataField>UnitsInStock</DataField>
<rd:TypeName>System.Int16</rd:TypeName>
</Field>
<Field Name="UnitsOnOrder">
<DataField>UnitsOnOrder</DataField>
<rd:TypeName>System.Int16</rd:TypeName>
</Field>
<Field Name="ReorderLevel">
<DataField>ReorderLevel</DataField>
<rd:TypeName>System.Int16</rd:TypeName>
</Field>
<Field Name="Discontinued">
<DataField>Discontinued</DataField>
<rd:TypeName>System.Boolean</rd:TypeName>
</Field>
<Field Name="CategoryName">
<DataField>CategoryName</DataField>
<rd:TypeName>System.String</rd:TypeName>
</Field>
<Field Name="Country">
<DataField>Country</DataField>
<rd:TypeName>System.String</rd:TypeName>
</Field>
</Fields>
<Query>
<DataSourceName>Northwind</DataSourceName>
<CommandText>SELECT Products.*, Categories.CategoryName,
Suppliers.Country
FROM Products INNER JOIN
Categories ON Products.CategoryID =Categories.CategoryID INNER JOIN
Suppliers ON Products.SupplierID =Suppliers.SupplierID</CommandText>
</Query>
</DataSet>
</DataSets>
<LeftMargin>1in</LeftMargin>
<rd:SnapToGrid>true</rd:SnapToGrid>
<rd:DrawGrid>true</rd:DrawGrid>
<rd:ReportID>e5564b0f-4fab-4cf7-9cef-bda726589920</rd:ReportID>
<BottomMargin>1in</BottomMargin>
<Language>en-US</Language>
</Report>|||I tried the code in the article but get the following error:
There is an error on line 14 of custom code: [BC30430] 'End Function' must
be preceded by a matching 'Function'.
Build complete -- 1 errors, 0 warnings
Any ideas?
"Robert Bruckner [MSFT]" wrote:
> I suggest to follow the approach discussed in this blog article:
> http://blogs.msdn.com/bwelcker/archive/2005/05/20/420349.aspx
> You don't need the part about the custom legend, but you should take a close
> look at the custom color part of the sample. You can modify the code so that
> instead of having the hashtable approach to apply unique colors for
> categories, you replace it with some IF statement to explicitly control
> colors.
> A trivial RDL sample with two charts using different filters but sharing the
> same colors for categories is copied to the bottom of this posting.
> -- Robert
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
> "anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
> news:69E297FD-F5C7-44D4-9463-5E4871B1CEAB@.microsoft.com...
> > Hello all!!
> >
> > I have created a pie chart that is embedded in a matrix report, therefore
> > creating a new pie for every row. The problem I am having is the pie
> > slice
> > for the same series is changing each time there is a new pie. For
> > example,
> > in the first pie Cars may be designated as green but in the second pie it
> > may
> > be red. I would like the colors to be consistent; all cars are
> > represented
> > as green slices. Oh and if there are no cars don't use the color green
> > for
> > another slice.
> >
> > I think this can be done using a nested expression but I am unsure how to
> > write it...I either need an example of an expression that can handle
> > multiple slices or another way to handle the issue.
> >
> > Thanks,
> > Anthony
>
> ============================================> <?xml version="1.0" encoding="utf-8"?>
> <Report
> xmlns="http://schemas.microsoft.com/sqlserver/reporting/2003/10/reportdefinition"
> xmlns:rd="">http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
> <RightMargin>1in</RightMargin>
> <Author>Robert M. Bruckner</Author>
> <Body>
> <ReportItems>
> <Chart Name="chart2">
> <ThreeDProperties>
> <Rotation>30</Rotation>
> <Inclination>30</Inclination>
> <Shading>Simple</Shading>
> <WallThickness>50</WallThickness>
> </ThreeDProperties>
> <ZIndex>1</ZIndex>
> <Style>
> <BackgroundColor>White</BackgroundColor>
> </Style>
> <Legend>
> <Visible>true</Visible>
> <Style>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> <Position>RightCenter</Position>
> </Legend>
> <Palette>Default</Palette>
> <ChartData>
> <ChartSeries>
> <DataPoints>
> <DataPoint>
> <DataValues>
> <DataValue>
> <Value>=Sum(Fields!UnitsInStock.Value)</Value>
> </DataValue>
> </DataValues>
> <DataLabel />
> <Style>
> <BackgroundColor>=Code.GetColor(Fields!CategoryName.Value)</BackgroundColor>
> </Style>
> <Marker>
> <Size>6pt</Size>
> </Marker>
> </DataPoint>
> </DataPoints>
> </ChartSeries>
> </ChartData>
> <CategoryAxis>
> <Axis>
> <Title />
> <MajorGridLines>
> <Style>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> </MajorGridLines>
> <MinorGridLines>
> <Style>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> </MinorGridLines>
> <Min>0</Min>
> </Axis>
> </CategoryAxis>
> <DataSetName>DataSet1</DataSetName>
> <PointWidth>0</PointWidth>
> <Type>Bar</Type>
> <Top>3.125in</Top>
> <Title>
> <Caption>UK</Caption>
> </Title>
> <Width>6in</Width>
> <SeriesGroupings>
> <SeriesGrouping>
> <DynamicSeries>
> <Grouping Name="chart2_SeriesGroup1">
> <GroupExpressions>
> <GroupExpression>=Fields!CategoryName.Value</GroupExpression>
> </GroupExpressions>
> </Grouping>
> <Sorting>
> <SortBy>
> <SortExpression>=Fields!CategoryName.Value</SortExpression>
> <Direction>Ascending</Direction>
> </SortBy>
> </Sorting>
> <Label>=Fields!CategoryName.Value</Label>
> </DynamicSeries>
> </SeriesGrouping>
> </SeriesGroupings>
> <Subtype>Plain</Subtype>
> <PlotArea>
> <Style>
> <BackgroundColor>LightGrey</BackgroundColor>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> </PlotArea>
> <Filters>
> <Filter>
> <FilterExpression>=Fields!Country.Value</FilterExpression>
> <Operator>Equal</Operator>
> <FilterValues>
> <FilterValue>UK</FilterValue>
> </FilterValues>
> </Filter>
> </Filters>
> <Left>0.125in</Left>
> <ValueAxis>
> <Axis>
> <Title />
> <MajorGridLines>
> <ShowGridLines>true</ShowGridLines>
> <Style>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> </MajorGridLines>
> <MinorGridLines>
> <Style>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> </MinorGridLines>
> <MajorTickMarks>Outside</MajorTickMarks>
> <Min>0</Min>
> <Margin>true</Margin>
> <Visible>true</Visible>
> <Scalar>true</Scalar>
> </Axis>
> </ValueAxis>
> </Chart>
> <Chart Name="chart1">
> <ThreeDProperties>
> <Rotation>30</Rotation>
> <Inclination>30</Inclination>
> <Shading>Simple</Shading>
> <WallThickness>50</WallThickness>
> </ThreeDProperties>
> <Style>
> <BackgroundColor>White</BackgroundColor>
> </Style>
> <Legend>
> <Visible>true</Visible>
> <Style>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> <Position>RightCenter</Position>
> </Legend>
> <Palette>Default</Palette>
> <ChartData>
> <ChartSeries>
> <DataPoints>
> <DataPoint>
> <DataValues>
> <DataValue>
> <Value>=Sum(Fields!UnitsInStock.Value)</Value>
> </DataValue>
> </DataValues>
> <DataLabel />
> <Style>
> <BackgroundColor>=Code.GetColor(Fields!CategoryName.Value)</BackgroundColor>
> </Style>
> <Marker>
> <Size>6pt</Size>
> </Marker>
> </DataPoint>
> </DataPoints>
> </ChartSeries>
> </ChartData>
> <CategoryAxis>
> <Axis>
> <Title />
> <MajorGridLines>
> <Style>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> </MajorGridLines>
> <MinorGridLines>
> <Style>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> </MinorGridLines>
> <Min>0</Min>
> </Axis>
> </CategoryAxis>
> <DataSetName>DataSet1</DataSetName>
> <PointWidth>0</PointWidth>
> <Type>Bar</Type>
> <Top>0.25in</Top>
> <Title>
> <Caption>USA</Caption>
> </Title>
> <Width>6in</Width>
> <Height>2.5in</Height>
> <SeriesGroupings>
> <SeriesGrouping>
> <DynamicSeries>
> <Grouping Name="chart1_SeriesGroup1">
> <GroupExpressions>
> <GroupExpression>=Fields!CategoryName.Value</GroupExpression>
> </GroupExpressions>
> </Grouping>
> <Sorting>
> <SortBy>
> <SortExpression>=Fields!CategoryName.Value</SortExpression>
> <Direction>Ascending</Direction>
> </SortBy>
> </Sorting>
> <Label>=Fields!CategoryName.Value</Label>
> </DynamicSeries>
> </SeriesGrouping>
> </SeriesGroupings>
> <Subtype>Plain</Subtype>
> <PlotArea>
> <Style>
> <BackgroundColor>LightGrey</BackgroundColor>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> </PlotArea>
> <Filters>
> <Filter>
> <FilterExpression>=Fields!Country.Value</FilterExpression>
> <Operator>Equal</Operator>
> <FilterValues>
> <FilterValue>USA</FilterValue>
> </FilterValues>
> </Filter>
> </Filters>
> <Left>0.125in</Left>
> <ValueAxis>
> <Axis>
> <Title />
> <MajorGridLines>
> <ShowGridLines>true</ShowGridLines>
> <Style>
> <BorderStyle>
> <Default>Solid</Default>
> </BorderStyle>
> </Style>
> </MajorGridLines>|||Did you try the sample I had attached to the bottom of my previous posting,
or did you download the other sample about custom legends from the blog
article? Both should work as provided.
In your particular case, the error message would indicate that you are
missing the Function keyword for the corresponding End Function statement on
line 14 of the custom code window of the report (VS menu -> report -> report
properties -> custom code)
-- Robert
This posting is provided "AS IS" with no warranties, and confers no rights.
"anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
news:13337779-49F4-44A7-B0B8-4963E58D2B75@.microsoft.com...
>I tried the code in the article but get the following error:
> There is an error on line 14 of custom code: [BC30430] 'End Function' must
> be preceded by a matching 'Function'.
> Build complete -- 1 errors, 0 warnings
>
> Any ideas?
> "Robert Bruckner [MSFT]" wrote:
>> I suggest to follow the approach discussed in this blog article:
>> http://blogs.msdn.com/bwelcker/archive/2005/05/20/420349.aspx
>> You don't need the part about the custom legend, but you should take a
>> close
>> look at the custom color part of the sample. You can modify the code so
>> that
>> instead of having the hashtable approach to apply unique colors for
>> categories, you replace it with some IF statement to explicitly control
>> colors.
>> A trivial RDL sample with two charts using different filters but sharing
>> the
>> same colors for categories is copied to the bottom of this posting.
>> -- Robert
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>>
>> "anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
>> news:69E297FD-F5C7-44D4-9463-5E4871B1CEAB@.microsoft.com...
>> > Hello all!!
>> >
>> > I have created a pie chart that is embedded in a matrix report,
>> > therefore
>> > creating a new pie for every row. The problem I am having is the pie
>> > slice
>> > for the same series is changing each time there is a new pie. For
>> > example,
>> > in the first pie Cars may be designated as green but in the second pie
>> > it
>> > may
>> > be red. I would like the colors to be consistent; all cars are
>> > represented
>> > as green slices. Oh and if there are no cars don't use the color green
>> > for
>> > another slice.
>> >
>> > I think this can be done using a nested expression but I am unsure how
>> > to
>> > write it...I either need an example of an expression that can handle
>> > multiple slices or another way to handle the issue.
>> >
>> > Thanks,
>> > Anthony
>>
>> ============================================>> <?xml version="1.0" encoding="utf-8"?>
>> <Report
>> xmlns="http://schemas.microsoft.com/sqlserver/reporting/2003/10/reportdefinition"
>> xmlns:rd="">http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
>> <RightMargin>1in</RightMargin>
>> <Author>Robert M. Bruckner</Author>
>> <Body>
>> <ReportItems>
>> <Chart Name="chart2">
>> <ThreeDProperties>
>> <Rotation>30</Rotation>
>> <Inclination>30</Inclination>
>> <Shading>Simple</Shading>
>> <WallThickness>50</WallThickness>
>> </ThreeDProperties>
>> <ZIndex>1</ZIndex>
>> <Style>
>> <BackgroundColor>White</BackgroundColor>
>> </Style>
>> <Legend>
>> <Visible>true</Visible>
>> <Style>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> <Position>RightCenter</Position>
>> </Legend>
>> <Palette>Default</Palette>
>> <ChartData>
>> <ChartSeries>
>> <DataPoints>
>> <DataPoint>
>> <DataValues>
>> <DataValue>
>> <Value>=Sum(Fields!UnitsInStock.Value)</Value>
>> </DataValue>
>> </DataValues>
>> <DataLabel />
>> <Style>
>> <BackgroundColor>=Code.GetColor(Fields!CategoryName.Value)</BackgroundColor>
>> </Style>
>> <Marker>
>> <Size>6pt</Size>
>> </Marker>
>> </DataPoint>
>> </DataPoints>
>> </ChartSeries>
>> </ChartData>
>> <CategoryAxis>
>> <Axis>
>> <Title />
>> <MajorGridLines>
>> <Style>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> </MajorGridLines>
>> <MinorGridLines>
>> <Style>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> </MinorGridLines>
>> <Min>0</Min>
>> </Axis>
>> </CategoryAxis>
>> <DataSetName>DataSet1</DataSetName>
>> <PointWidth>0</PointWidth>
>> <Type>Bar</Type>
>> <Top>3.125in</Top>
>> <Title>
>> <Caption>UK</Caption>
>> </Title>
>> <Width>6in</Width>
>> <SeriesGroupings>
>> <SeriesGrouping>
>> <DynamicSeries>
>> <Grouping Name="chart2_SeriesGroup1">
>> <GroupExpressions>
>> <GroupExpression>=Fields!CategoryName.Value</GroupExpression>
>> </GroupExpressions>
>> </Grouping>
>> <Sorting>
>> <SortBy>
>> <SortExpression>=Fields!CategoryName.Value</SortExpression>
>> <Direction>Ascending</Direction>
>> </SortBy>
>> </Sorting>
>> <Label>=Fields!CategoryName.Value</Label>
>> </DynamicSeries>
>> </SeriesGrouping>
>> </SeriesGroupings>
>> <Subtype>Plain</Subtype>
>> <PlotArea>
>> <Style>
>> <BackgroundColor>LightGrey</BackgroundColor>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> </PlotArea>
>> <Filters>
>> <Filter>
>> <FilterExpression>=Fields!Country.Value</FilterExpression>
>> <Operator>Equal</Operator>
>> <FilterValues>
>> <FilterValue>UK</FilterValue>
>> </FilterValues>
>> </Filter>
>> </Filters>
>> <Left>0.125in</Left>
>> <ValueAxis>
>> <Axis>
>> <Title />
>> <MajorGridLines>
>> <ShowGridLines>true</ShowGridLines>
>> <Style>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> </MajorGridLines>
>> <MinorGridLines>
>> <Style>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> </MinorGridLines>
>> <MajorTickMarks>Outside</MajorTickMarks>
>> <Min>0</Min>
>> <Margin>true</Margin>
>> <Visible>true</Visible>
>> <Scalar>true</Scalar>
>> </Axis>
>> </ValueAxis>
>> </Chart>
>> <Chart Name="chart1">
>> <ThreeDProperties>
>> <Rotation>30</Rotation>
>> <Inclination>30</Inclination>
>> <Shading>Simple</Shading>
>> <WallThickness>50</WallThickness>
>> </ThreeDProperties>
>> <Style>
>> <BackgroundColor>White</BackgroundColor>
>> </Style>
>> <Legend>
>> <Visible>true</Visible>
>> <Style>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> <Position>RightCenter</Position>
>> </Legend>
>> <Palette>Default</Palette>
>> <ChartData>
>> <ChartSeries>
>> <DataPoints>
>> <DataPoint>
>> <DataValues>
>> <DataValue>
>> <Value>=Sum(Fields!UnitsInStock.Value)</Value>
>> </DataValue>
>> </DataValues>
>> <DataLabel />
>> <Style>
>> <BackgroundColor>=Code.GetColor(Fields!CategoryName.Value)</BackgroundColor>
>> </Style>
>> <Marker>
>> <Size>6pt</Size>
>> </Marker>
>> </DataPoint>
>> </DataPoints>
>> </ChartSeries>
>> </ChartData>
>> <CategoryAxis>
>> <Axis>
>> <Title />
>> <MajorGridLines>
>> <Style>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> </MajorGridLines>
>> <MinorGridLines>
>> <Style>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> </MinorGridLines>
>> <Min>0</Min>
>> </Axis>
>> </CategoryAxis>
>> <DataSetName>DataSet1</DataSetName>
>> <PointWidth>0</PointWidth>
>> <Type>Bar</Type>
>> <Top>0.25in</Top>
>> <Title>
>> <Caption>USA</Caption>
>> </Title>
>> <Width>6in</Width>
>> <Height>2.5in</Height>
>> <SeriesGroupings>
>> <SeriesGrouping>
>> <DynamicSeries>
>> <Grouping Name="chart1_SeriesGroup1">
>> <GroupExpressions>
>> <GroupExpression>=Fields!CategoryName.Value</GroupExpression>
>> </GroupExpressions>
>> </Grouping>
>> <Sorting>
>> <SortBy>
>> <SortExpression>=Fields!CategoryName.Value</SortExpression>
>> <Direction>Ascending</Direction>
>> </SortBy>
>> </Sorting>
>> <Label>=Fields!CategoryName.Value</Label>
>> </DynamicSeries>
>> </SeriesGrouping>
>> </SeriesGroupings>
>> <Subtype>Plain</Subtype>
>> <PlotArea>
>> <Style>
>> <BackgroundColor>LightGrey</BackgroundColor>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> </PlotArea>
>> <Filters>
>> <Filter>
>> <FilterExpression>=Fields!Country.Value</FilterExpression>
>> <Operator>Equal</Operator>
>> <FilterValues>
>> <FilterValue>USA</FilterValue>
>> </FilterValues>
>> </Filter>
>> </Filters>
>> <Left>0.125in</Left>
>> <ValueAxis>
>> <Axis>
>> <Title />
>> <MajorGridLines>
>> <ShowGridLines>true</ShowGridLines>
>> <Style>
>> <BorderStyle>
>> <Default>Solid</Default>
>> </BorderStyle>
>> </Style>
>> </MajorGridLines>|||I used the code off the site I had to change the Private to Public because I
was getting errors and the only way I got them to go away was to change
Private to Public.
The code I have in the report properties code tab is as follows:
Public colorPalette As String() = {"Green", "Blue", "Red", "Orange", "Aqua",
"Teal", "Gold", "RoyalBlue", "#A59D93", "#B8341B", "#352F26", "#F1E7D6",
"#E16C56", "#CFBA9B"}
Public count As Integer = 0
Public mapping As New System.Collections.Hashtable()
Public Function GetColor(ByVal groupingValue As String) As String
If mapping.ContainsKey(groupingValue) Then
Return mapping(groupingValue)
End If
Dim c As String = colorPalette(count Mod colorPalette.Length)
count = count + 1
mapping.Add(groupingValue, c)
Return c
End Function
The Data field for my chart is: YTD
The Series field is: Project_Category
for the Data field properties on my Pie chart I went to the apperance tab
then series style... on the fill tab, color field I put the following FX:
=Code.GetColor(Fields!Project_Category.Value)
Any ideas what I am missing?
I also tried the following code that someone modified off your code example
with no luck either...
In Chart Properties, Data, Values, Edit, Appearance, Series Style I use this
function:
= Code.GetColor(Fields!Project_Category.Value)
And in the code for the report I have:
Public Function GetColor(ByVal Project_Category As String) As String
if Project_Category = "Value 1" Then
Return "#CC3333" ' "Red"
end if
if Project_Category = "Value 2" Then
Return "Pink"
end if
if Project_Category = "Value 3" Then
Return "#3300CC" ' "Blue"
end if
if (Project_Category <> "Value 1") and (Project_Category <> "Value 2") and
(Project_Category
<> "Project_Category") Then
Return "Black"
end if
End Function
again no luck with this one.....
THANKS AGAIN FOR ALL THE HELP!!!
"Robert Bruckner [MSFT]" wrote:
> Did you try the sample I had attached to the bottom of my previous posting,
> or did you download the other sample about custom legends from the blog
> article? Both should work as provided.
> In your particular case, the error message would indicate that you are
> missing the Function keyword for the corresponding End Function statement on
> line 14 of the custom code window of the report (VS menu -> report -> report
> properties -> custom code)
> -- Robert
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
> "anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
> news:13337779-49F4-44A7-B0B8-4963E58D2B75@.microsoft.com...
> >I tried the code in the article but get the following error:
> >
> > There is an error on line 14 of custom code: [BC30430] 'End Function' must
> > be preceded by a matching 'Function'.
> > Build complete -- 1 errors, 0 warnings
> >
> >
> > Any ideas?
> >
> > "Robert Bruckner [MSFT]" wrote:
> >
> >> I suggest to follow the approach discussed in this blog article:
> >> http://blogs.msdn.com/bwelcker/archive/2005/05/20/420349.aspx
> >>
> >> You don't need the part about the custom legend, but you should take a
> >> close
> >> look at the custom color part of the sample. You can modify the code so
> >> that
> >> instead of having the hashtable approach to apply unique colors for
> >> categories, you replace it with some IF statement to explicitly control
> >> colors.
> >>
> >> A trivial RDL sample with two charts using different filters but sharing
> >> the
> >> same colors for categories is copied to the bottom of this posting.
> >>
> >> -- Robert
> >> This posting is provided "AS IS" with no warranties, and confers no
> >> rights.
> >>
> >>
> >> "anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
> >> news:69E297FD-F5C7-44D4-9463-5E4871B1CEAB@.microsoft.com...
> >> > Hello all!!
> >> >
> >> > I have created a pie chart that is embedded in a matrix report,
> >> > therefore
> >> > creating a new pie for every row. The problem I am having is the pie
> >> > slice
> >> > for the same series is changing each time there is a new pie. For
> >> > example,
> >> > in the first pie Cars may be designated as green but in the second pie
> >> > it
> >> > may
> >> > be red. I would like the colors to be consistent; all cars are
> >> > represented
> >> > as green slices. Oh and if there are no cars don't use the color green
> >> > for
> >> > another slice.
> >> >
> >> > I think this can be done using a nested expression but I am unsure how
> >> > to
> >> > write it...I either need an example of an expression that can handle
> >> > multiple slices or another way to handle the issue.
> >> >
> >> > Thanks,
> >> > Anthony
> >>
> >>
> >> ============================================> >>
> >> <?xml version="1.0" encoding="utf-8"?>
> >> <Report
> >> xmlns="http://schemas.microsoft.com/sqlserver/reporting/2003/10/reportdefinition"
> >> xmlns:rd="">http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
> >> <RightMargin>1in</RightMargin>
> >> <Author>Robert M. Bruckner</Author>
> >> <Body>
> >> <ReportItems>
> >> <Chart Name="chart2">
> >> <ThreeDProperties>
> >> <Rotation>30</Rotation>
> >> <Inclination>30</Inclination>
> >> <Shading>Simple</Shading>
> >> <WallThickness>50</WallThickness>
> >> </ThreeDProperties>
> >> <ZIndex>1</ZIndex>
> >> <Style>
> >> <BackgroundColor>White</BackgroundColor>
> >> </Style>
> >> <Legend>
> >> <Visible>true</Visible>
> >> <Style>
> >> <BorderStyle>
> >> <Default>Solid</Default>
> >> </BorderStyle>
> >> </Style>
> >> <Position>RightCenter</Position>
> >> </Legend>
> >> <Palette>Default</Palette>
> >> <ChartData>
> >> <ChartSeries>
> >> <DataPoints>
> >> <DataPoint>
> >> <DataValues>
> >> <DataValue>
> >> <Value>=Sum(Fields!UnitsInStock.Value)</Value>
> >> </DataValue>
> >> </DataValues>
> >> <DataLabel />
> >> <Style>
> >>
> >> <BackgroundColor>=Code.GetColor(Fields!CategoryName.Value)</BackgroundColor>
> >> </Style>
> >> <Marker>
> >> <Size>6pt</Size>
> >> </Marker>
> >> </DataPoint>
> >> </DataPoints>
> >> </ChartSeries>
> >> </ChartData>
> >> <CategoryAxis>
> >> <Axis>
> >> <Title />
> >> <MajorGridLines>
> >> <Style>
> >> <BorderStyle>
> >> <Default>Solid</Default>
> >> </BorderStyle>
> >> </Style>
> >> </MajorGridLines>
> >> <MinorGridLines>
> >> <Style>
> >> <BorderStyle>
> >> <Default>Solid</Default>
> >> </BorderStyle>
> >> </Style>
> >> </MinorGridLines>
> >> <Min>0</Min>
> >> </Axis>
> >> </CategoryAxis>
> >> <DataSetName>DataSet1</DataSetName>
> >> <PointWidth>0</PointWidth>
> >> <Type>Bar</Type>
> >> <Top>3.125in</Top>
> >> <Title>
> >> <Caption>UK</Caption>
> >> </Title>
> >> <Width>6in</Width>
> >> <SeriesGroupings>
> >> <SeriesGrouping>
> >> <DynamicSeries>
> >> <Grouping Name="chart2_SeriesGroup1">
> >> <GroupExpressions>
> >>
> >> <GroupExpression>=Fields!CategoryName.Value</GroupExpression>
> >> </GroupExpressions>
> >> </Grouping>
> >> <Sorting>
> >> <SortBy>
> >>
> >> <SortExpression>=Fields!CategoryName.Value</SortExpression>
> >> <Direction>Ascending</Direction>
> >> </SortBy>
> >> </Sorting>
> >> <Label>=Fields!CategoryName.Value</Label>
> >> </DynamicSeries>
> >> </SeriesGrouping>
> >> </SeriesGroupings>
> >> <Subtype>Plain</Subtype>
> >> <PlotArea>
> >> <Style>
> >> <BackgroundColor>LightGrey</BackgroundColor>
> >> <BorderStyle>
> >> <Default>Solid</Default>
> >> </BorderStyle>
> >> </Style>
> >> </PlotArea>
> >> <Filters>
> >> <Filter>
> >> <FilterExpression>=Fields!Country.Value</FilterExpression>
> >> <Operator>Equal</Operator>
> >> <FilterValues>
> >> <FilterValue>UK</FilterValue>
> >> </FilterValues>
> >> </Filter>
> >> </Filters>
> >> <Left>0.125in</Left>
> >> <ValueAxis>
> >> <Axis>
> >> <Title />
> >> <MajorGridLines>
> >> <ShowGridLines>true</ShowGridLines>
> >> <Style>
> >> <BorderStyle>
> >> <Default>Solid</Default>
> >> </BorderStyle>
> >> </Style>
> >> </MajorGridLines>
> >> <MinorGridLines>
> >> <Style>
> >> <BorderStyle>
> >> <Default>Solid</Default>
> >> </BorderStyle>
> >> </Style>
> >> </MinorGridLines>
> >> <MajorTickMarks>Outside</MajorTickMarks>
> >> <Min>0</Min>
> >> <Margin>true</Margin>
> >> <Visible>true</Visible>
> >> <Scalar>true</Scalar>
> >> </Axis>
> >> </ValueAxis>
> >> </Chart>
> >> <Chart Name="chart1">
> >> <ThreeDProperties>
> >> <Rotation>30</Rotation>
> >> <Inclination>30</Inclination>
> >> <Shading>Simple</Shading>
> >> <WallThickness>50</WallThickness>
> >> </ThreeDProperties>
> >> <Style>
> >> <BackgroundColor>White</BackgroundColor>
> >> </Style>
> >> <Legend>
> >> <Visible>true</Visible>
> >> <Style>
> >> <BorderStyle>
> >> <Default>Solid</Default>
> >> </BorderStyle>
> >> </Style>
> >> <Position>RightCenter</Position>
> >> </Legend>
> >> <Palette>Default</Palette>
> >> <ChartData>
> >> <ChartSeries>
> >> <DataPoints>
> >> <DataPoint>
> >> <DataValues>
> >> <DataValue>
> >> <Value>=Sum(Fields!UnitsInStock.Value)</Value>
> >> </DataValue>
> >> </DataValues>
> >> <DataLabel />
> >> <Style>
> >>
> >> <BackgroundColor>=Code.GetColor(Fields!CategoryName.Value)</BackgroundColor>
> >> </Style>
> >> <Marker>
> >> <Size>6pt</Size>
> >> </Marker>
> >> </DataPoint>
> >> </DataPoints>
> >> </ChartSeries>
> >> </ChartData>
> >> <CategoryAxis>
> >> <Axis>
> >> <Title />
> >> <MajorGridLines>
> >> <Style>
> >> <BorderStyle>
> >> <Default>Solid</Default>
> >> </BorderStyle>
> >> </Style>
> >> </MajorGridLines>
> >> <MinorGridLines>
> >> <Style>
> >> <BorderStyle>
> >> <Default>Solid</Default>
> >> </BorderStyle>
> >> </Style>
> >> </MinorGridLines>
> >> <Min>0</Min>
> >> </Axis>
> >> </CategoryAxis>
> >> <DataSetName>DataSet1</DataSetName>
> >> <PointWidth>0</PointWidth>
> >> <Type>Bar</Type>
> >> <Top>0.25in</Top>
> >> <Title>
> >> <Caption>USA</Caption>
> >> </Title>
> >> <Width>6in</Width>
> >> <Height>2.5in</Height>
> >> <SeriesGroupings>
> >> <SeriesGrouping>
> >> <DynamicSeries>
> >> <Grouping Name="chart1_SeriesGroup1">
> >> <GroupExpressions>
> >>
> >> <GroupExpression>=Fields!CategoryName.Value</GroupExpression>
> >> </GroupExpressions>
> >> </Grouping>
> >> <Sorting>|||Robert,
I found the problem with the code that I got from your blog article....in
all the cutting and pasting I ended up with a second end function that I
needed to scroll down to see.
Good thing is that the code is working...bad thing is I am getting the same
results. What I am trying to do is almost like conditional formatting. If
you return a specific value I want to return a specific color, the next value
will have another color assigned, and so on. All in all I should have no
more than 5-6 values that I need to define colors for.
I tried the following code which I think is more like what I am wanting:
In Chart Properties, Data, Values, Edit, Appearance, Series Style I use this
function:
= Code.GetColor(Fields!Project_Category.Value)
And in the code for the report I have:
Public Function GetColor(ByVal Project_Category As String) As String
if Project_Category = "Value 1" Then
Return "#CC3333" ' "Red"
end if
if Project_Category = "Value 2" Then
Return "Pink"
end if
if Project_Category = "Value 3" Then
Return "#3300CC" ' "Blue"
end if
if (Project_Category <> "Value 1") and (Project_Category <> "Value 2") and
(Project_Category
<> "Value 3") Then
Return "Black"
end if
End Function
However, as I stated below I can't seem to get it to work because of the
following error:
There is an error on line 10 of custom code: [BC30201] Expression expected.
Build complete -- 1 errors, 0 warnings
I also thought of writing an IIF but I think the nesting could get pretty
complex....
"anthonysjo" wrote:
> I used the code off the site I had to change the Private to Public because I
> was getting errors and the only way I got them to go away was to change
> Private to Public.
> The code I have in the report properties code tab is as follows:
> Public colorPalette As String() = {"Green", "Blue", "Red", "Orange", "Aqua",
> "Teal", "Gold", "RoyalBlue", "#A59D93", "#B8341B", "#352F26", "#F1E7D6",
> "#E16C56", "#CFBA9B"}
> Public count As Integer = 0
> Public mapping As New System.Collections.Hashtable()
> Public Function GetColor(ByVal groupingValue As String) As String
> If mapping.ContainsKey(groupingValue) Then
> Return mapping(groupingValue)
> End If
> Dim c As String = colorPalette(count Mod colorPalette.Length)
> count = count + 1
> mapping.Add(groupingValue, c)
> Return c
> End Function
> The Data field for my chart is: YTD
> The Series field is: Project_Category
> for the Data field properties on my Pie chart I went to the apperance tab
> then series style... on the fill tab, color field I put the following FX:
> =Code.GetColor(Fields!Project_Category.Value)
> Any ideas what I am missing?
> I also tried the following code that someone modified off your code example
> with no luck either...
> In Chart Properties, Data, Values, Edit, Appearance, Series Style I use this
> function:
> = Code.GetColor(Fields!Project_Category.Value)
> And in the code for the report I have:
> Public Function GetColor(ByVal Project_Category As String) As String
> if Project_Category = "Value 1" Then
> Return "#CC3333" ' "Red"
> end if
> if Project_Category = "Value 2" Then
> Return "Pink"
> end if
> if Project_Category = "Value 3" Then
> Return "#3300CC" ' "Blue"
> end if
> if (Project_Category <> "Value 1") and (Project_Category <> "Value 2") and
> (Project_Category
> <> "Project_Category") Then
> Return "Black"
> end if
> End Function
> again no luck with this one.....
> THANKS AGAIN FOR ALL THE HELP!!!
> "Robert Bruckner [MSFT]" wrote:
> > Did you try the sample I had attached to the bottom of my previous posting,
> > or did you download the other sample about custom legends from the blog
> > article? Both should work as provided.
> >
> > In your particular case, the error message would indicate that you are
> > missing the Function keyword for the corresponding End Function statement on
> > line 14 of the custom code window of the report (VS menu -> report -> report
> > properties -> custom code)
> >
> > -- Robert
> > This posting is provided "AS IS" with no warranties, and confers no rights.
> >
> >
> >
> > "anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
> > news:13337779-49F4-44A7-B0B8-4963E58D2B75@.microsoft.com...
> > >I tried the code in the article but get the following error:
> > >
> > > There is an error on line 14 of custom code: [BC30430] 'End Function' must
> > > be preceded by a matching 'Function'.
> > > Build complete -- 1 errors, 0 warnings
> > >
> > >
> > > Any ideas?
> > >
> > > "Robert Bruckner [MSFT]" wrote:
> > >
> > >> I suggest to follow the approach discussed in this blog article:
> > >> http://blogs.msdn.com/bwelcker/archive/2005/05/20/420349.aspx
> > >>
> > >> You don't need the part about the custom legend, but you should take a
> > >> close
> > >> look at the custom color part of the sample. You can modify the code so
> > >> that
> > >> instead of having the hashtable approach to apply unique colors for
> > >> categories, you replace it with some IF statement to explicitly control
> > >> colors.
> > >>
> > >> A trivial RDL sample with two charts using different filters but sharing
> > >> the
> > >> same colors for categories is copied to the bottom of this posting.
> > >>
> > >> -- Robert
> > >> This posting is provided "AS IS" with no warranties, and confers no
> > >> rights.
> > >>
> > >>
> > >> "anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
> > >> news:69E297FD-F5C7-44D4-9463-5E4871B1CEAB@.microsoft.com...
> > >> > Hello all!!
> > >> >
> > >> > I have created a pie chart that is embedded in a matrix report,
> > >> > therefore
> > >> > creating a new pie for every row. The problem I am having is the pie
> > >> > slice
> > >> > for the same series is changing each time there is a new pie. For
> > >> > example,
> > >> > in the first pie Cars may be designated as green but in the second pie
> > >> > it
> > >> > may
> > >> > be red. I would like the colors to be consistent; all cars are
> > >> > represented
> > >> > as green slices. Oh and if there are no cars don't use the color green
> > >> > for
> > >> > another slice.
> > >> >
> > >> > I think this can be done using a nested expression but I am unsure how
> > >> > to
> > >> > write it...I either need an example of an expression that can handle
> > >> > multiple slices or another way to handle the issue.
> > >> >
> > >> > Thanks,
> > >> > Anthony
> > >>
> > >>
> > >> ============================================> > >>
> > >> <?xml version="1.0" encoding="utf-8"?>
> > >> <Report
> > >> xmlns="http://schemas.microsoft.com/sqlserver/reporting/2003/10/reportdefinition"
> > >> xmlns:rd="">http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
> > >> <RightMargin>1in</RightMargin>
> > >> <Author>Robert M. Bruckner</Author>
> > >> <Body>
> > >> <ReportItems>
> > >> <Chart Name="chart2">
> > >> <ThreeDProperties>
> > >> <Rotation>30</Rotation>
> > >> <Inclination>30</Inclination>
> > >> <Shading>Simple</Shading>
> > >> <WallThickness>50</WallThickness>
> > >> </ThreeDProperties>
> > >> <ZIndex>1</ZIndex>
> > >> <Style>
> > >> <BackgroundColor>White</BackgroundColor>
> > >> </Style>
> > >> <Legend>
> > >> <Visible>true</Visible>
> > >> <Style>
> > >> <BorderStyle>
> > >> <Default>Solid</Default>
> > >> </BorderStyle>
> > >> </Style>
> > >> <Position>RightCenter</Position>
> > >> </Legend>
> > >> <Palette>Default</Palette>
> > >> <ChartData>
> > >> <ChartSeries>
> > >> <DataPoints>
> > >> <DataPoint>
> > >> <DataValues>
> > >> <DataValue>
> > >> <Value>=Sum(Fields!UnitsInStock.Value)</Value>
> > >> </DataValue>
> > >> </DataValues>
> > >> <DataLabel />
> > >> <Style>
> > >>
> > >> <BackgroundColor>=Code.GetColor(Fields!CategoryName.Value)</BackgroundColor>
> > >> </Style>
> > >> <Marker>
> > >> <Size>6pt</Size>
> > >> </Marker>
> > >> </DataPoint>
> > >> </DataPoints>
> > >> </ChartSeries>
> > >> </ChartData>
> > >> <CategoryAxis>
> > >> <Axis>
> > >> <Title />
> > >> <MajorGridLines>
> > >> <Style>
> > >> <BorderStyle>
> > >> <Default>Solid</Default>
> > >> </BorderStyle>
> > >> </Style>
> > >> </MajorGridLines>
> > >> <MinorGridLines>
> > >> <Style>
> > >> <BorderStyle>
> > >> <Default>Solid</Default>
> > >> </BorderStyle>
> > >> </Style>
> > >> </MinorGridLines>
> > >> <Min>0</Min>
> > >> </Axis>
> > >> </CategoryAxis>
> > >> <DataSetName>DataSet1</DataSetName>
> > >> <PointWidth>0</PointWidth>
> > >> <Type>Bar</Type>
> > >> <Top>3.125in</Top>
> > >> <Title>
> > >> <Caption>UK</Caption>
> > >> </Title>
> > >> <Width>6in</Width>
> > >> <SeriesGroupings>
> > >> <SeriesGrouping>
> > >> <DynamicSeries>
> > >> <Grouping Name="chart2_SeriesGroup1">
> > >> <GroupExpressions>
> > >>
> > >> <GroupExpression>=Fields!CategoryName.Value</GroupExpression>
> > >> </GroupExpressions>
> > >> </Grouping>
> > >> <Sorting>
> > >> <SortBy>
> > >>
> > >> <SortExpression>=Fields!CategoryName.Value</SortExpression>
> > >> <Direction>Ascending</Direction>
> > >> </SortBy>
> > >> </Sorting>
> > >> <Label>=Fields!CategoryName.Value</Label>
> > >> </DynamicSeries>
> > >> </SeriesGrouping>
> > >> </SeriesGroupings>
> > >> <Subtype>Plain</Subtype>
> > >> <PlotArea>
> > >> <Style>
> > >> <BackgroundColor>LightGrey</BackgroundColor>
> > >> <BorderStyle>
> > >> <Default>Solid</Default>
> > >> </BorderStyle>
> > >> </Style>
> > >> </PlotArea>
> > >> <Filters>
> > >> <Filter>
> > >> <FilterExpression>=Fields!Country.Value</FilterExpression>
> > >> <Operator>Equal</Operator>
> > >> <FilterValues>
> > >> <FilterValue>UK</FilterValue>
> > >> </FilterValues>
> > >> </Filter>
> > >> </Filters>
> > >> <Left>0.125in</Left>
> > >> <ValueAxis>
> > >> <Axis>
> > >> <Title />
> > >> <MajorGridLines>
> > >> <ShowGridLines>true</ShowGridLines>
> > >> <Style>
> > >> <BorderStyle>
> > >> <Default>Solid</Default>
> > >> </BorderStyle>
> > >> </Style>
> > >> </MajorGridLines>
> > >> <MinorGridLines>
> > >> <Style>
> > >> <BorderStyle>
> > >> <Default>Solid</Default>
> > >> </BorderStyle>
> > >> </Style>
> > >> </MinorGridLines>
> > >> <MajorTickMarks>Outside</MajorTickMarks>
> > >> <Min>0</Min>
> > >> <Margin>true</Margin>
> > >> <Visible>true</Visible>
> > >> <Scalar>true</Scalar>
> > >> </Axis>
> > >> </ValueAxis>
> > >> </Chart>
> > >> <Chart Name="chart1">
> > >> <ThreeDProperties>
> > >> <Rotation>30</Rotation>
> > >> <Inclination>30</Inclination>
> > >> <Shading>Simple</Shading>
> > >> <WallThickness>50</WallThickness>
> > >> </ThreeDProperties>
> > >> <Style>
> > >> <BackgroundColor>White</BackgroundColor>
> > >> </Style>
> > >> <Legend>
> > >> <Visible>true</Visible>
> > >> <Style>
> > >> <BorderStyle>
> > >> <Default>Solid</Default>
> > >> </BorderStyle>
> > >> </Style>|||All is well!!! I took the following code:
= Code.GetColor(Fields!Project_Category.Value)
> And in the code for the report I have:
> Public Function GetColor(ByVal Project_Category As String) As String
> if Project_Category = "Value 1" Then
> Return "#CC3333" ' "Red"
> end if
> if Project_Category = "Value 2" Then
> Return "Pink"
> end if
> if Project_Category = "Value 3" Then
> Return "#3300CC" ' "Blue"
> end if
> if (Project_Category <> "Value 1") and (Project_Category <> "Value 2") and
> (Project_Category
> <> "Value 3") Then
> Return "Black"
> end if
> End Function
Then removed this....
if (Project_Category <> "Value 1") and (Project_Category <> "Value 2") and
> (Project_Category
> <> "Value 3") Then
> Return "Black"
> end if
Everything works great now!!!!
Thanks for all the help!!
"anthonysjo" wrote:
> Robert,
> I found the problem with the code that I got from your blog article....in
> all the cutting and pasting I ended up with a second end function that I
> needed to scroll down to see.
> Good thing is that the code is working...bad thing is I am getting the same
> results. What I am trying to do is almost like conditional formatting. If
> you return a specific value I want to return a specific color, the next value
> will have another color assigned, and so on. All in all I should have no
> more than 5-6 values that I need to define colors for.
> I tried the following code which I think is more like what I am wanting:
> In Chart Properties, Data, Values, Edit, Appearance, Series Style I use this
> function:
> = Code.GetColor(Fields!Project_Category.Value)
> And in the code for the report I have:
> Public Function GetColor(ByVal Project_Category As String) As String
> if Project_Category = "Value 1" Then
> Return "#CC3333" ' "Red"
> end if
> if Project_Category = "Value 2" Then
> Return "Pink"
> end if
> if Project_Category = "Value 3" Then
> Return "#3300CC" ' "Blue"
> end if
> if (Project_Category <> "Value 1") and (Project_Category <> "Value 2") and
> (Project_Category
> <> "Value 3") Then
> Return "Black"
> end if
> End Function
> However, as I stated below I can't seem to get it to work because of the
> following error:
> There is an error on line 10 of custom code: [BC30201] Expression expected.
> Build complete -- 1 errors, 0 warnings
> I also thought of writing an IIF but I think the nesting could get pretty
> complex....
> "anthonysjo" wrote:
> > I used the code off the site I had to change the Private to Public because I
> > was getting errors and the only way I got them to go away was to change
> > Private to Public.
> >
> > The code I have in the report properties code tab is as follows:
> > Public colorPalette As String() = {"Green", "Blue", "Red", "Orange", "Aqua",
> > "Teal", "Gold", "RoyalBlue", "#A59D93", "#B8341B", "#352F26", "#F1E7D6",
> > "#E16C56", "#CFBA9B"}
> > Public count As Integer = 0
> > Public mapping As New System.Collections.Hashtable()
> >
> > Public Function GetColor(ByVal groupingValue As String) As String
> > If mapping.ContainsKey(groupingValue) Then
> > Return mapping(groupingValue)
> > End If
> > Dim c As String = colorPalette(count Mod colorPalette.Length)
> > count = count + 1
> > mapping.Add(groupingValue, c)
> > Return c
> > End Function
> >
> > The Data field for my chart is: YTD
> > The Series field is: Project_Category
> >
> > for the Data field properties on my Pie chart I went to the apperance tab
> > then series style... on the fill tab, color field I put the following FX:
> > =Code.GetColor(Fields!Project_Category.Value)
> >
> > Any ideas what I am missing?
> >
> > I also tried the following code that someone modified off your code example
> > with no luck either...
> >
> > In Chart Properties, Data, Values, Edit, Appearance, Series Style I use this
> > function:
> >
> > = Code.GetColor(Fields!Project_Category.Value)
> >
> > And in the code for the report I have:
> >
> > Public Function GetColor(ByVal Project_Category As String) As String
> > if Project_Category = "Value 1" Then
> > Return "#CC3333" ' "Red"
> > end if
> > if Project_Category = "Value 2" Then
> > Return "Pink"
> > end if
> > if Project_Category = "Value 3" Then
> > Return "#3300CC" ' "Blue"
> > end if
> > if (Project_Category <> "Value 1") and (Project_Category <> "Value 2") and
> > (Project_Category
> > <> "Project_Category") Then
> > Return "Black"
> > end if
> > End Function
> >
> > again no luck with this one.....
> >
> > THANKS AGAIN FOR ALL THE HELP!!!
> >
> > "Robert Bruckner [MSFT]" wrote:
> >
> > > Did you try the sample I had attached to the bottom of my previous posting,
> > > or did you download the other sample about custom legends from the blog
> > > article? Both should work as provided.
> > >
> > > In your particular case, the error message would indicate that you are
> > > missing the Function keyword for the corresponding End Function statement on
> > > line 14 of the custom code window of the report (VS menu -> report -> report
> > > properties -> custom code)
> > >
> > > -- Robert
> > > This posting is provided "AS IS" with no warranties, and confers no rights.
> > >
> > >
> > >
> > > "anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
> > > news:13337779-49F4-44A7-B0B8-4963E58D2B75@.microsoft.com...
> > > >I tried the code in the article but get the following error:
> > > >
> > > > There is an error on line 14 of custom code: [BC30430] 'End Function' must
> > > > be preceded by a matching 'Function'.
> > > > Build complete -- 1 errors, 0 warnings
> > > >
> > > >
> > > > Any ideas?
> > > >
> > > > "Robert Bruckner [MSFT]" wrote:
> > > >
> > > >> I suggest to follow the approach discussed in this blog article:
> > > >> http://blogs.msdn.com/bwelcker/archive/2005/05/20/420349.aspx
> > > >>
> > > >> You don't need the part about the custom legend, but you should take a
> > > >> close
> > > >> look at the custom color part of the sample. You can modify the code so
> > > >> that
> > > >> instead of having the hashtable approach to apply unique colors for
> > > >> categories, you replace it with some IF statement to explicitly control
> > > >> colors.
> > > >>
> > > >> A trivial RDL sample with two charts using different filters but sharing
> > > >> the
> > > >> same colors for categories is copied to the bottom of this posting.
> > > >>
> > > >> -- Robert
> > > >> This posting is provided "AS IS" with no warranties, and confers no
> > > >> rights.
> > > >>
> > > >>
> > > >> "anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
> > > >> news:69E297FD-F5C7-44D4-9463-5E4871B1CEAB@.microsoft.com...
> > > >> > Hello all!!
> > > >> >
> > > >> > I have created a pie chart that is embedded in a matrix report,
> > > >> > therefore
> > > >> > creating a new pie for every row. The problem I am having is the pie
> > > >> > slice
> > > >> > for the same series is changing each time there is a new pie. For
> > > >> > example,
> > > >> > in the first pie Cars may be designated as green but in the second pie
> > > >> > it
> > > >> > may
> > > >> > be red. I would like the colors to be consistent; all cars are
> > > >> > represented
> > > >> > as green slices. Oh and if there are no cars don't use the color green
> > > >> > for
> > > >> > another slice.
> > > >> >
> > > >> > I think this can be done using a nested expression but I am unsure how
> > > >> > to
> > > >> > write it...I either need an example of an expression that can handle
> > > >> > multiple slices or another way to handle the issue.
> > > >> >
> > > >> > Thanks,
> > > >> > Anthony
> > > >>
> > > >>
> > > >> ============================================> > > >>
> > > >> <?xml version="1.0" encoding="utf-8"?>
> > > >> <Report
> > > >> xmlns="http://schemas.microsoft.com/sqlserver/reporting/2003/10/reportdefinition"
> > > >> xmlns:rd="">http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
> > > >> <RightMargin>1in</RightMargin>
> > > >> <Author>Robert M. Bruckner</Author>
> > > >> <Body>
> > > >> <ReportItems>
> > > >> <Chart Name="chart2">
> > > >> <ThreeDProperties>
> > > >> <Rotation>30</Rotation>
> > > >> <Inclination>30</Inclination>
> > > >> <Shading>Simple</Shading>
> > > >> <WallThickness>50</WallThickness>
> > > >> </ThreeDProperties>
> > > >> <ZIndex>1</ZIndex>
> > > >> <Style>
> > > >> <BackgroundColor>White</BackgroundColor>
> > > >> </Style>
> > > >> <Legend>
> > > >> <Visible>true</Visible>
> > > >> <Style>
> > > >> <BorderStyle>
> > > >> <Default>Solid</Default>
> > > >> </BorderStyle>
> > > >> </Style>
> > > >> <Position>RightCenter</Position>
> > > >> </Legend>
> > > >> <Palette>Default</Palette>
> > > >> <ChartData>
> > > >> <ChartSeries>
> > > >> <DataPoints>
> > > >> <DataPoint>
> > > >> <DataValues>
> > > >> <DataValue>
> > > >> <Value>=Sum(Fields!UnitsInStock.Value)</Value>
> > > >> </DataValue>
> > > >> </DataValues>
> > > >> <DataLabel />
> > > >> <Style>
> > > >>
> > > >> <BackgroundColor>=Code.GetColor(Fields!CategoryName.Value)</BackgroundColor>
> > > >> </Style>
> > > >> <Marker>
> > > >> <Size>6pt</Size>
> > > >> </Marker>
> > > >> </DataPoint>
> > > >> </DataPoints>
> > > >> </ChartSeries>
> > > >> </ChartData>
> > > >> <CategoryAxis>
> > > >> <Axis>
> > > >> <Title />
> > > >> <MajorGridLines>
> > > >> <Style>
> > > >> <BorderStyle>
> > > >> <Default>Solid</Default>
> > > >> </BorderStyle>
> > > >> </Style>
> > > >> </MajorGridLines>
> > > >> <MinorGridLines>
> > > >> <Style>
> > > >> <BorderStyle>
> > > >> <Default>Solid</Default>
> > > >> </BorderStyle>
> > > >> </Style>
> > > >> </MinorGridLines>
> > > >> <Min>0</Min>
> > > >> </Axis>
> > > >> </CategoryAxis>
> > > >> <DataSetName>DataSet1</DataSetName>
> > > >> <PointWidth>0</PointWidth>
> > > >> <Type>Bar</Type>
> > > >> <Top>3.125in</Top>
> > > >> <Title>
> > > >> <Caption>UK</Caption>
> > > >> </Title>
> > > >> <Width>6in</Width>
> > > >> <SeriesGroupings>
> > > >> <SeriesGrouping>
> > > >> <DynamicSeries>
> > > >> <Grouping Name="chart2_SeriesGroup1">
> > > >> <GroupExpressions>
> > > >>
> > > >> <GroupExpression>=Fields!CategoryName.Value</GroupExpression>
> > > >> </GroupExpressions>
> > > >> </Grouping>
> > > >> <Sorting>
> > > >> <SortBy>
> > > >>
> > > >> <SortExpression>=Fields!CategoryName.Value</SortExpression>
> > > >> <Direction>Ascending</Direction>
> > > >> </SortBy>
> > > >> </Sorting>
> > > >> <Label>=Fields!CategoryName.Value</Label>
> > > >> </DynamicSeries>
> > > >> </SeriesGrouping>
> > > >> </SeriesGroupings>
> > > >> <Subtype>Plain</Subtype>
> > > >> <PlotArea>
> > > >> <Style>
> > > >> <BackgroundColor>LightGrey</BackgroundColor>
> > > >> <BorderStyle>
> > > >> <Default>Solid</Default>
> > > >> </BorderStyle>
> > > >> </Style>
> > > >> </PlotArea>
> > > >> <Filters>
> > > >> <Filter>
> > > >> <FilterExpression>=Fields!Country.Value</FilterExpression>
> > > >> <Operator>Equal</Operator>