⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 versionhistory.aspx

📁 掌握学习.net开发的非常好的资料
💻 ASPX
字号:
<%@ Page Language="C#" Description="dotnetCHARTING Component"%>
<%@ Register TagPrefix="dotnet"  Namespace="dotnetCHARTING" Assembly="dotnetCHARTING"%>
<%@ Import Namespace="System.Drawing" %>


<script runat="server">
void Page_Load(Object sender,EventArgs e)
{
    //set global properties
    Chart.Size="1000X500";
    Chart.DefaultSeries.ConnectionString = @"../../database/chartsample.mdb";  
    Chart.Title=".netCHARTING Version Releases";
    Chart.TempDirectory="temp";
    Chart.Type=ChartType.Scatter;
    Chart.XAxis.Scale = Scale.Time;
    Chart.Debug=true;
    Chart.LegendBox.Template = "%Icon %Name";
    Chart.ChartArea.Label.Text = "Click a version to view the version history at the .netCHARTING web site.";
    Chart.TitleBox.Position = TitleBoxPosition.FullWithLegend;

    //Set Axis Interval and Minimum values
    Chart.YAxis.Interval = 1;
    Chart.YAxis.Minimum = 1;
    
    //Set xAxis Minimum and Maximum values
    Chart.XAxis.Minimum = new DateTime(2002,11,1);
    Chart.XAxis.Maximum = new DateTime(2005,12,31);
    Chart.XAxis.FormatString="MMM, yyyy";

    //Format date display on X Axis
    Chart.XAxis.TimeInterval = TimeInterval.Months;

    //Show values for all elements across all series and set marker size to 15
    Chart.DefaultSeries.DefaultElement.Marker.Size=7;
    Chart.DefaultSeries.DefaultElement.ShowValue=true;

    //Use custom attribute pulled from db, version, and inline format the date in the template
    Chart.DefaultSeries.DefaultElement.SmartLabel.Text = "%Version Released <%XValue,MM/dd/yy>";

    //Link all elements to the version history page and set a tooltip for them as well
    Chart.DefaultSeries.DefaultElement.URL = "http://www.dotnetcharting.com/versionhistory.aspx";
    Chart.DefaultSeries.DefaultElement.ToolTip = "View Version History Page";

    //Add a series, define a custom attribute for version and splitby for version creating a series for each
    Chart.Series.Type = SeriesType.Marker;
    Chart.Series.SqlStatement= @"SELECT ReleaseDate,ReleaseNumber,Version FROM Versions";
    Chart.Series.DataFields="YValue=ReleaseNumber,XValue=ReleaseDate,SplitBy=Version,Version";
    Chart.SeriesCollection.Add();       
}
</script>
<HTML><HEAD><TITLE>.netCHARTING Releases</TITLE></HEAD>
<BODY>
<DIV align=center>
 <dotnet:Chart id="Chart"  runat="server"/>
</DIV>
</BODY>
</BODY>
</HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -