webchart控件的饼图 如何显示百分比。既在块上有一条线,后跟百分之几
(提供链接的就不用了,谢谢)

解决方案 »

  1.   

    http://www.51aspx.com/CodeImg/211-1.jpg
    你不想要连接也就是要源码咯。这里有源码
    http://www.51aspx.com/CV/WebChartPie/
      

  2.   


    for ( int  i = 0 ; i  <  dv.Count; i ++ )
    {
    C1.Win.C1Chart.Label lbl  =  C1WebChart1.ChartLabels.LabelsCollection.AddNewLabel();
    lbl.Text  =   string .Format( " {0}% " , float .Parse(dv[i][ " value " ].ToString()));
    lbl.Compass  =  LabelCompassEnum.Radial;
    lbl.Offset  =   20 ;
    lbl.Connected  =   true ;
    lbl.Visible  =   true ;
    lbl.AttachMethod  =  AttachMethodEnum.DataIndex;
    AttachMethodData am  =  lbl.AttachMethodData;
    am.GroupIndex   =   0 ;
    am.SeriesIndex  =  i;
    am.PointIndex   =   0 ;
    } C1是什么
    C1WebChart1是什么
      

  3.   

    dotnetCHARTING.DLL用的上面控件,可以实现圆饼每个分区显示百分比.
            //for (int i = 0; i < rcs.Count; i++)
            //{
            //    Series se = new Series();
            //    se.Name = rcs[i]["l_lostcause"];
            //    Element ee = new Element();
            //    ee.Name = rcs[i]["l_lostcause"];
            //    ee.YValue = Convert.ToDouble( rcs[i]["Num"]);
            //    se.Elements.Add(ee);
            //    pieC.SeriesCollection.Add(se);        //    Count += Convert.ToInt32(rcs[i]["Num"]);
            //}        //设置是否显示百分比
             //pieC.DefaultSeries.DefaultElement.ShowValue = true;
            //pieC.Title = "总数:" + Count.ToString();