ASP.NET MSChart入門ChartArea詳細解(三).

2814 ワード

これはChartAreaを定義する方法です
        /// 

        ///   ChartArea

        /// 

        /// ChartArea  

        ///     3D

        /// 

        public static ChartArea SetChartAreaStyle(string name, bool Area3DStyle)

        {

 

            ChartArea mycharArea = new ChartArea(name);

            mycharArea.AxisX.LineColor = System.Drawing.Color.FromArgb(64, 64, 64, 64);

            mycharArea.AxisX.LabelStyle.Font = new System.Drawing.Font("Trebuchet MS", float.Parse("8.25"), FontStyle.Regular);

            mycharArea.AxisX.MajorGrid.LineColor = System.Drawing.Color.FromArgb(64, 64, 64, 64);

 

            mycharArea.AxisY.LineColor = System.Drawing.Color.FromArgb(64, 64, 64, 64);

            mycharArea.AxisY.LabelStyle.Font = new System.Drawing.Font("Trebuchet MS", float.Parse("8.25"), FontStyle.Regular);

            mycharArea.AxisY.MajorGrid.LineColor = System.Drawing.Color.FromArgb(64, 64, 64, 64);

 

            if (Area3DStyle)

            {

                mycharArea.Area3DStyle.Enable3D = true;

                mycharArea.Area3DStyle.IsRightAngleAxes = false;//    

                mycharArea.Area3DStyle.IsClustered = false;

                //Chart1.ChartAreas["ChartArea1"].Area3DStyle.WallWidth = 0; //  3D         

 

 

                mycharArea.Area3DStyle.Inclination = 15;//X   

                mycharArea.Area3DStyle.Rotation = 10;//Y   

                mycharArea.Area3DStyle.Perspective = 10;

 

            }

 

            mycharArea.BackColor = System.Drawing.Color.FromArgb(64, 165, 191, 228);

            // BackSecondaryColor="Transparent" BorderColor="64, 64, 64, 64" 

            mycharArea.BackSecondaryColor = System.Drawing.Color.Transparent;

            mycharArea.BorderColor = System.Drawing.Color.FromArgb(64, 64, 64, 64);

            mycharArea.AxisY.ScaleBreakStyle.Enabled = true;//         

            //mycharArea.AxisX.Interval = 1; 

            //mycharArea.AxisY.Interval = 5000; //   Y      5000  

 

            //mycharArea.AxisX.MajorGrid.Interval = 1;

 

            //mycharArea.Area3DStyle.Enable3D = true;

            //mycharArea.AlignmentOrientation = AreaAlignmentOrientations.Horizontal;

            //mycharArea.AxisY.Enabled = AxisEnabled.False;

            //mycharArea.AxisY2.Enabled = AxisEnabled.True;

            //mycharArea.AxisX.LabelStyle.IsEndLabelVisible = false;           

 

            return mycharArea;

 

        }

  

中には役に立つものがある
       mycharArea.AxisY.ScaleBreakStyle.Enabled = true;//比较的に异なる东东を开いて今図をアップロードさせないでさもなくば効果を见ることができます
       mycharArea.Area3DStyle.Enable3D = true;//3 D表示を開く
他のプロパティプログラムの注釈には