MSChart learning help-develop log (2). net 3.5 chart controls

Source: Internet
Author: User

I carefully read how Scott developed MSchart, but I still don't understand it. The original saying is: ASP. NET 3.5 can be used for free. However, I saw the license again in the MSChart section on the official website. If someone really wants to use it, I can call Microsoft's sales phone number 8008203800 or wait for me to know. I will answer the question for you, because of this good thing, I will definitely find a chance to use it in my project.

Today, MSChart is taken out for research. Because there is no help document, no cases and materials are available on the Internet. The only help is Microsoft's 200 examples. Let's look at the source code, look at the attributes, and try the functions of each attribute-_-this is very hard

Okay, I finally got to understand some of the practices of the two graphs first.

I posted the source code to the front-end.

<Asp: chart id = "Chart1" runat = "server" Height = "250px" Width = "400px" <br/> ImageLocation = "~ /TempImages/ChartPic _ # SEQ (, 3) "Palette =" BrightPastel "<br/> imagetype =" Png "BorderDashStyle =" Solid "BackSecondaryColor =" White "<br/> BackGradientStyle =" TopBottom "BorderWidth =" 2 "backcolor = "# D3DFF0"> <br/> <legends> <br/> <asp: legend IsTextAutoFit = "true" Name = "Default" BackColor = "Transparent" Font = "Trebuchet MS, 8.25pt, style =" Bold "mce_style =" Bold "> </asp: legend> <br/> </legends> <br/> <border Skin skinstyle = "Emboss"> </borderskin> <br/> <series> <br/> <asp: series Name = "2007 Air" <br/> CustomProperties = "MinPixelPointWidth = 1, PixelPointWidth = 30, DrawingStyle = Cylinder, MaxPixelPointWidth = 30, DrawSideBySide = True, pointWidth = 0 "<br/> Color =" 224,224,224 "Font =" Times New Roman, 9pt "MarkerColor =" Navy "MarkerSize =" 12 "<br/> BorderWidth =" 3 "ShadowOffset =" 2 "IsValueShownAsLabel =" True "<br/> Lab ElForeColor = "64, 0, 0"> <br/> <points> <br/> <asp: dataPoint YValues = "0.9" AxisLabel = "BBU"/> <br/> <asp: DataPoint YValues = "0.9" AxisLabel = "MCBU"/> <br/> <asp: dataPoint YValues = "0.91" AxisLabel = "TBU"/> <br/> </points> <br/> <EmptyPointStyle IsValueShownAsLabel = "True" LabelAngle = "15" <br/> LabelBackColor = "Olive" LabelForeColor = "RosyBrown" MarkerSize = "12"/> <br/> <SmartLabelStyle CalloutLineColor = "DarkRed" CalloutLineAnchorCapStyle = "Diamond" <br/> CalloutStyle = "None"/> <br/> </asp: series> <br/> </series> <br/> <chartareas> <br/> <asp: ChartArea Name = "Air" BorderColor = "64, 64, 64, 64 "BorderDashStyle =" Solid "BackSecondaryColor =" White "BackColor =" 64,165,191,228 "ShadowColor =" Transparent "BackGradientStyle =" TopBottom "> <br/> <area3dstyle PointDepth =" 150 "PointGapDepth = "150" Rotation = "15" Perspective = "2" Inclination = "20" LightStyle = "Realistic" wallwidth = "0" IsClustered = "False"> </area3dstyle> </p> <axisy linecolor = "64, 64, 64, 64 "> <br/> <labelstyle font =" Trebuchet MS, 8.25pt, style = "Bold" mce_style = "Bold"/> <br/> <majorgrid linecolor = "64, 64, 64, 64 "/> <br/> </axisy> <br/> <axisx linecolor =" 64, 64, 64, 64 "& gt; <br/> <labelstyle font =" Trebuchet MS, 8.25pt, style = "Bold" mce_styl E = "Bold" "/> <br/> <majorgrid linecolor =" 64, 64, 64, 64 "/> <br/> </axisx> <br/> </asp: ChartArea> <br/> </chartareas> <br/> </asp: chart> <br/> <asp: chart id = "Chart2" runat = "server" Height = "250px" Width = "400px" <br/> ImageLocation = "~ /TempImages/ChartPic _ # SEQ (, 3) "Palette =" BrightPastel "<br/> imagetype =" Png "BorderDashStyle =" Solid "BackSecondaryColor =" White "<br/> BackGradientStyle =" TopBottom "BorderWidth =" 2 "backcolor = "# D3DFF0"> <br/> <legends> <br/> <asp: legend IsTextAutoFit = "true" Alignment = "Center" Docking = "Top" Name = "Default" BackColor = "Transparent" Font = "Trebuchet MS, 8.25pt, style = "Bold" mce_style = "Bold"> </asp: legend> <br/> </legends> <br/> <borderskin skinstyle = "Emboss"> </borderskin> <br/> <series> <br/> <asp: series Name = "TBU int '1 (Ship/CW) "MarkerSize =" 8 "BorderWidth =" 3 "<br/> XValueType =" Double "ChartType =" Line "MarkerStyle =" Circle "ShadowColor =" Black "<br/> BorderColor = "180, 26, 59,105 "Color =" Red "ShadowOffset =" 2 "<br/> YValueType =" Double "> <br/> </asp: series> <br/> <asp: Series Name = "TBU China (include GSM) (Ship/CW) "ChartType = Line <br/> BorderWidth =" 3 "ShadowOffset =" 2 "MarkerSize =" 8 "MarkerStyle =" Circle "<br/> ShadowColor =" Black "BorderColor =" 180, 26, 59,105 "> <br/> </asp: Series> <br/> </series> <br/> <chartareas> <br/> <asp: chartArea Name = "Ship/CW" BorderColor = "64, 64, 64, 64 "<br/> BorderDashStyle =" Solid "BackSecondaryColor =" White "<br/> BackColor =" 64,165,191,228 "ShadowColor =" Transparent "<br/> BackGradientStyle =" TopBottom "success = "True"> <br/> <area3dstyle PointDepth = "150" PointGapDepth = "150" Rotation = "15" perspective = "2" Inclination = "20" LightStyle = "Realistic "wallwidth =" 0 "IsClustered =" False "> </area3dstyle> </p> <axisy linecolor =" 64, 64, 64, 64 "> <br/> <labelstyle font =" Trebuchet MS, 8.25pt, style = "Bold" mce_style = "Bold"/> <br/> <majorgrid linecolor = "64, 64, 64, 64 "/> <br/> </axisy> <br/> <axisx linecolor =" 64, 64, 64, 64 "& gt; <br/> <labelstyle font =" Trebuchet MS, 8.25pt, style = "Bold" mce_style = "Bold"/> <br/> <majorgrid linecolor = "64, 64, 64, 64 "/> <br/> </axisx> <br/> </asp: ChartArea> <br/> </chartareas> <br/> </asp: chart>

This is the background

Protected void Page_Load (object sender, EventArgs e) <br/>{< br/> showAirExample (); <br/> ShowPointExample (); <br/>}< br/> protected void showAirExample () <br/>{< br/> Series series = new Series ("2008 Air "); <br/> series. chartType = SeriesChartType. column; <br/> series ["DrawingStyle"] = "Cylinder"; <br/> series. isValueShownAsLabel = true; <br/> series. borderWidth = 3; <br/> series. shadowOffset = 2; <br/> series ["PixelPointWidth"] = "30"; <br/> // Populate new series with data <br/> series. points. addY (0.281); <br/> series. points. addY (1); <br/> series. points. addY (1); <br/> // Add series into the chart's series collection <br/> Chart1.Series. add (series); <br/> Chart1.Series ["2008 Air"]. chartType = SeriesChartType. column; <br/> // Show as 3D <br/> Chart1.ChartAreas ["Air"]. area3DStyle. enable3D = false; <br/> // Draw as 3D Cylinder <br/> Chart1.Series ["2008 Air"] ["DrawingStyle"] = "Cylinder "; <br/> Chart1.Series ["2008 Air"]. labelForeColor = Color. fromArgb (0, 0,192); <br/>}< br/> protected void ShowPointExample () {<br/> Random random = new Random (); <br/> for (int pointIndex = 0; pointIndex <5; pointIndex ++) <br/> {<br/> Chart2.Series [0]. points. addY (random. next (45, 95); <br/> Chart2.Series [1]. points. addY (random. next (5, 75 )); <br/>}</p> <p> // Set point labels <br/> // Chart2.Series ["TBU int '1 (Ship/CW)"]. isValueShownAsLabel = true; </p> <p> // Chart2.Series ["TBU China (include GSM) (Ship/CW)"]. isValueShownAsLabel = true; <br/> // Enable X axis margin <br/> Chart2.ChartAreas ["Ship/CW"]. axisX. isMarginVisible = false; <br/> // Enable 3D, and show data point marker lines <br/> Chart2.ChartAreas ["Ship/CW"]. area3DStyle. enable3D = false; <br/> Chart2.Series [0] ["ShowMarkerLines"] = "True"; <br/> Chart2.Series [1] ["ShowMarkerLines"] = "True "; <br/>}

How to configure it is what I mentioned in the previous article. Here, we can see how vs2008 developed the 3D report MSChart and downloaded the development log with attachments throughout the development process (I)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.