This question is locked. New answers and comments are not allowed.
Hello -
I am having issues applying a theme to a Silverlight RadChart that uses Drill Down logic in a single chart area. I created a sample project based on the exact source code found here (http://www.telerik.com/help/silverlight/radchart-features-drill-down-in-a-single-chart-area.html). When I issue a StyleManager.SetTheme call to any theme other than Office_BlackTheme a blank page is rendered in the browser Is there something I am missing?
Thanks -
I am having issues applying a theme to a Silverlight RadChart that uses Drill Down logic in a single chart area. I created a sample project based on the exact source code found here (http://www.telerik.com/help/silverlight/radchart-features-drill-down-in-a-single-chart-area.html). When I issue a StyleManager.SetTheme call to any theme other than Office_BlackTheme a blank page is rendered in the browser Is there something I am missing?
Thanks -
using
System;
using
System.Collections.Generic;
using
System.Linq;
using
System.Net;
using
System.Windows;
using
System.Windows.Controls;
using
System.Windows.Documents;
using
System.Windows.Input;
using
System.Windows.Media;
using
System.Windows.Media.Animation;
using
System.Windows.Shapes;
using
Telerik.Windows.Controls.Charting;
using
Telerik.Windows.Controls;
namespace
SLTestDrillDown
{
public
partial
class
MainPage : UserControl
{
public
MainPage()
{
InitializeComponent();
radChart.ItemsSource = GetChartData();
//this does not work. Setting to any other skin besides Office_BlackTheme
//causes the page to not render
//A blank page is displayed in the browser
StyleManager.SetTheme(radChart,
new
VistaTheme());
//this is the only theme that works
//StyleManager.SetTheme(radChart, new Office_BlackTheme());
}
private
List<Company> GetChartData()
{
return
new
List<Company>() {
new
Company() {
Name=
"ToyYoda"
,
Sales =
new
ModelSalesCollection() {
new
ModelSales(
"Coolla"
, 120000),
new
ModelSales(
"Coolla"
, 115000),
new
ModelSales(
"Veso"
, 89000),
new
ModelSales(
"Veso"
, 79000)
}
},
new
Company() {
Name=
"Marda"
,
Sales =
new
ModelSalesCollection() {
new
ModelSales(
"Tree"
, 145000),
new
ModelSales(
"Tree"
, 132000),
new
ModelSales(
"Six"
, 121000),
new
ModelSales(
"Six"
, 111000)
}
}
};
}
}
public
class
Company
{
public
string
Name
{
get
;
set
;
}
public
ModelSalesCollection Sales
{
get
;
set
;
}
}
public
class
ModelSalesCollection : List<ModelSales>
{
public
double
TotalAmount
{
get
{
return
this
.Sum(modelSales => modelSales.Amount);
}
}
}
public
class
ModelSales
{
public
string
Model
{
get
;
set
;
}
public
double
Amount
{
get
;
set
;
}
public
ModelSales(
string
model,
double
amount)
{
this
.Model = model;
this
.Amount = amount;
}
}
}