Highchartsnet Quick Chart Control-open source

Source: Internet
Author: User

Objective:

Highchartsnet Quick Chart Control, Highcharts-based ASP. You can quickly generate a chart with just a few lines of code.

Never worry about the complexity of the chart. Simple lines of code can be done, saving a lot of work time.

Built-in Highcharts, but only for personal study use, if business is required, please follow Highcharts Licensing.

Control Features:

Support for DataBind () the same as Microsoft other data controls directly databind () data source support DataTable DataSet.

No need to add references, built-in Highcharts jQuery.

Github:https://github.com/linezero/highchartsnet

Let me explain how to use it:

How to use:

First add HighchartsNET.dll to the project reference.

Register highchartsnet on the page

<%@ Register tagprefix="Zero" namespace="highchartsnet" assembly="highchartsnet" %>

Then add a highchartsnet control on the page

<zero:highcharts runat="server" id="highcharts1" title=" histogram "/>

Finally, add the binding code to the Page_Load.

1         //The above part is just analog data2DataTable dt =NewDataTable ();3Dt. Columns.Add ("a");4Dt. Columns.Add ("b");5DataRow dr =dt. NewRow ();6dr[0] ="2013/1";7dr[1] =" -";8 dt. Rows.Add (DR);9DataRow DR1 =dt. NewRow ();Tendr1[0] ="2013/2"; Onedr1[1] =" Max"; A dt. Rows.Add (DR1); -  -         //The chart requires only this part of the Code theHighcharts1. Type =HighchartsNET.ChartType.Column; -Highcharts1. DataKey ="a"; -Highcharts1. DataValue ="b"; -Highcharts1. YAxis ="rainfall (mm)";//the value of the y-axis; +Highcharts1. Tooltip ="valuesuffix: ' mm '"; -Highcharts1. Dataname ="Wuhan"; +Highcharts1. Legend =true;//whether to display the flag, default to False AHighcharts1. DataSource =DT; atHighcharts1. DataBind ();

The end result is as follows:

It's very simple to generate the charts you need. has been practiced in practical projects and feels very convenient.

Property Description:

        /// <summary>        ///Chart Title/// </summary>[Description ("Chart Title")]         Public stringTitle {Get;Set; } /// <summary>        ///Chart Type/// </summary>         PublicChartType Type {Get;Set; } /// <summary>        ///Chart Level 2 headings/// </summary>         Public stringSubTitle {Get;Set; } /// <summary>        ///Data Objects/// </summary>         PublicChartsseries Series {Get;Set; } /// <summary>        ///some additional options/// </summary>         Public stringplotoptions {Get;Set; } /// <summary>        ///x-Axis options/// </summary>         Publiclist<Object> Xaxis {Get;Set; } /// <summary>        ///The y-axis option can be filled by name only/// </summary>         Public stringYAxis {Get;Set; } /// <summary>        ///prompt Format/// </summary>         Public stringTooltip {Get;Set; } /// <summary>        ///Chart Layer ID (container)/// </summary>         Public stringdivID {Get;Set; } /// <summary>        ///icon below identifies whether the display is not displayed by default/// </summary>         Public BOOLLegend {Get;Set; } /// <summary>        ///advanced features, multiple datasets, multiple charts, pie charts not required. /// </summary>         PublicList<chartsseries> Serieslist {Get;Set; }  Public OverrideUnit Width {Get            {                return Base.            Width; }            Set            {                Base. Width =value; }        }         Public OverrideUnit Height {Get            {                                return Base.            Height; }            Set            {                Base. Height =value; }        }        Private BOOLNoScript =true; /// <summary>        ///whether to automatically refer to the script, default to True to false that requires adding a JS reference manually/// </summary>         Public BOOLNoScript {Get{returnNoScript;} Set{NoScript =value;} }         Public stringDataKey {Get;Set; }  Public stringDataValue {Get;Set; }  Public ObjectDataSource {Get;Set; }  Public ObjectDataname {Get;Set; }

For more detailed examples, see: Https://github.com/linezero/HighchartsNET

Sentiment:

This was at this time last year, but also in order to complete the beginning of the work of a homework.

Announced today, just to make it easier for everyone to achieve the required chart, save code time, away from overtime.

If you have any suggestions, or bugs please submit to https://github.com/linezero/HighchartsNET/issues.

If you think this article is helpful to you, please click " recommend ", thank you.

Highchartsnet Quick Chart Control-open source

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.