protected void Page_Load(object sender, System.EventArgs e) { // Populate series data double[] valueY = { 120, 530, 670, 430, 860, 240, 350, 870, 540, 120 }; double[] valueY2 = { 58, 94, 24, 56, 99, 12, 25 }; Chart1.Series["Series1"].Points.DataBindY(valueY, valueY2); // Use point index for drawing the chart Chart1.Series["Series1"].IsXValueIndexed = true; // Get sorting order PointSortOrder order = PointSortOrder.Ascending; if (SortOrderList.SelectedItem.Text == "Descending") { order = PointSortOrder.Descending; } // Sort series data points if (SortList.SelectedItem.Text == "Y Value") { Chart1.DataManipulator.Sort(order, "Y", "Series1"); } if (SortList.SelectedItem.Text == "Y2 Value (Radius)") { Chart1.DataManipulator.Sort(order, "Y2", "Series1"); } // Enable sort order control if (SortList.SelectedItem.Text != "Unsorted") { SortOrderList.Enabled = true; } }
private void FillChartData() { // Populate series data double[] valueY = { 120, 530, 670, 430, 860, 240, 350, 870, 540, 120 }; double[] valueY2 = { 58, 94, 24, 56, 99, 12, 25 }; chart1.Series["Series1"].Points.DataBindY(valueY, valueY2); // Use point index for drawing the chart chart1.Series["Series1"].IsXValueIndexed = true; // Get sorting order PointSortOrder order = PointSortOrder.Ascending; if (comboBoxSortOrder.Text == "Descending") { order = PointSortOrder.Descending; } // Sort series data points if (comboBoxSortingValue.Text == "Y Value") { chart1.DataManipulator.Sort(order, "Y", "Series1"); } if (comboBoxSortingValue.Text == "Y2 Value (Radius)") { chart1.DataManipulator.Sort(order, "Y2", "Series1"); } // Enable sort order control if (comboBoxSortingValue.Text != "Unsorted") { comboBoxSortOrder.Enabled = true; } else { comboBoxSortOrder.Enabled = false; } }
public void AlignDataPointsByAxisLabel (string series, PointSortOrder sortingOrder) { throw new NotImplementedException (); }
public void DataBindCrossTable (System.Collections.IEnumerable dataSource, string seriesGroupByField, string xField, string yFields, string otherFields, PointSortOrder sortingOrder) { throw new NotImplementedException (); }
public void AlignDataPointsByAxisLabel(string series, PointSortOrder sortingOrder) { throw new NotImplementedException(); }
public void DataBindCrossTable(System.Collections.IEnumerable dataSource, string seriesGroupByField, string xField, string yFields, string otherFields, PointSortOrder sortingOrder) { throw new NotImplementedException(); }
public void Sort (PointSortOrder pointSortOrder) { throw new NotImplementedException (); }
public void Sort (PointSortOrder pointSortOrder,string sortBy) { throw new NotImplementedException(); }
public List <PointHistoryEntity> GetPagedList(PagerRequest request, out int totalCount, PointSortOrder sortOrder) { return (base.Get(GetFilter(null, DataStatus.Normal), out totalCount, request.PageIndex, request.PageSize, GetOrder(sortOrder)) .ToList()); }
/// <summary> /// 排序 /// </summary> /// <param name="sort"></param> /// <returns></returns> private static Func <IQueryable <PointHistoryEntity>, IOrderedQueryable <PointHistoryEntity> > GetOrder(PointSortOrder sort) { Func <IQueryable <PointHistoryEntity>, IOrderedQueryable <PointHistoryEntity> > order = null; switch (sort) { case PointSortOrder.CreatedDateDesc: case PointSortOrder.Default: default: order = v => v.OrderByDescending(s => s.CreatedDate); break; } return(order); }
public void Sort(PointSortOrder pointSortOrder, string sortBy, Series series) { throw new NotImplementedException(); }
public void Sort(PointSortOrder pointSortOrder, string seriesName) { throw new NotImplementedException(); }
public void Sort(PointSortOrder pointSortOrder) { throw new NotImplementedException(); }