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

can see only broken image for the chart

3 Answers 36 Views
RadControls
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
sudha
Top achievements
Rank 1
sudha asked on 14 Dec 2007, 10:02 AM

Hi,
  I was trying to use the chart control in my sharepoint webpart but i can see only a broken image.
  i have copied the RadChart.Net2 dll to the  gac and the safe control entry is given below
  <SafeControl Assembly="RadChart.Net2, Version= 3.1.2.0,Culture=neutral, PublicKeyToken=d14f3dcc8e3e8763" Namespace="Telerik.Charting" TypeName="*" Safe="True" />
  <SafeControl Assembly="RadChart.Net2, Version= 3.1.2.0,Culture=neutral, PublicKeyToken=d14f3dcc8e3e8763" Namespace="Telerik.WebControls" TypeName="*" Safe="True" />
  I have copied the radcontrols folder to "C:\Program Files\Common Files\Microsoft Shared\web server extensions\wpresources"
  and my code is :

  public class CustomerPortal : System.Web.UI.WebControls.WebParts.WebPart
    {
        RadChart radChart = new RadChart();                        
        protected override void Render(HtmlTextWriter writer)
        {         
            EnsureChildControls();
            RenderChildren(writer);                                  
        }
        protected override void CreateChildControls()
        {                      
            // Create a ChartSeries and assign its name and chart type

            ChartSeries chartSeries = new ChartSeries();
            chartSeries.Name = "Sales";
            chartSeries.Type = ChartSeriesType.Bar;

            // add new items to the series,
            // passing a value and a label string
            chartSeries.AddItem(120, "Internet");
            chartSeries.AddItem(140, "Retail");
            chartSeries.AddItem(35, "Wholesale");
            radChart.Series.Add(chartSeries);   
                         
            radChart.RadControlsDir = "~/_wpresources/RadControls";
                             
            this.Controls.Add(radChart);                   
        }                                                  
    }
 I have the trial version (zip) of your controls.  
   Please help.
Thanks,
Sudha.M

3 Answers, 1 is accepted

Sort by
0
Vladimir Milev
Telerik team
answered on 19 Dec 2007, 08:12 AM
Hi sudha,

Your configuration seems correct. I just want to check several things:
-Have you tried the following path (no ~): radChart.RadControlsDir = "/_wpresources/RadControls";
-Can you make sure sufficient access priviliges were given to the RadControls dir and all its files?
-Can you make sure the RadControls dir is not configured as a web application?

If you are continuing to have problems you can try to access the chart image URL directly and observe the http response for more information.

Kind regards,
Vladimir Milev
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
AECLDEV
Top achievements
Rank 1
answered on 04 Jan 2008, 04:51 PM
I am experiencing exactly the same issue.  I have checked all the things in the second post, to no avail.  Is there anything else that could be doing this?
0
Vladimir Milev
Telerik team
answered on 10 Jan 2008, 07:58 AM
Hi AECLDEV,

Have you followed the relevant steps from this tutorial? Have you excluded file access permissions from the list of possible problems?

Regards,
Vladimir Milev
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
RadControls
Asked by
sudha
Top achievements
Rank 1
Answers by
Vladimir Milev
Telerik team
AECLDEV
Top achievements
Rank 1
Share this question
or