在这里做个备注:

  public partial class XtraForm2 : DevExpress.XtraEditors.XtraForm
    {
        private LabelControl _labelControl;
        private int xpoint;
        private int yponit;
        public XtraForm2()
        {
            InitializeComponent();
            _labelControl = new LabelControl();
            chartControl1.Controls.Add(_labelControl);
            chartControl1.MouseClick += new MouseEventHandler(ChartControl1MouseClick);
        }

        void ChartControl1MouseClick(object sender, MouseEventArgs e)
        {
            xpoint = e.X;
            yponit = e.Y;
        }
        private void ChartControl1ObjectSelected(object sender, DevExpress.XtraCharts.HotTrackEventArgs e)
        {
            
            if (e.AdditionalObject == null) return;
            SeriesPoint point = (SeriesPoint)e.AdditionalObject;
            string ms = string.Format("Value{0},argument:{1}", point.ValuesSerializable, point.Argument);         
            _labelControl.Text = string.Empty;
            _labelControl.Location = new Point(xpoint, yponit);
            _labelControl.Text = "值:" + point.ValuesSerializable;
           

        }


    }

 

相关文章:

  • 2021-10-19
  • 2022-12-23
  • 2022-12-23
  • 2022-01-16
  • 2022-01-08
  • 2021-12-27
  • 2022-12-23
  • 2022-02-28
猜你喜欢
  • 2022-12-23
  • 2021-08-13
  • 2022-12-23
  • 2021-12-25
  • 2021-12-25
  • 2022-12-23
相关资源
相似解决方案