我使图表线收集点。当我绘制2个点(20,20)和(40,40)时,它起作用,但是当我将图形中间的点(30,0)绘制为三角形时。 我需要修复什么?提前谢谢。
我是代码:
<i>
private void btnConfirm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
{
ChartControl point = new ChartControl();
float s_question_true = 0;
int percent;
int dexibel = 0;
float trunggian;
CheckEdit[] _checkBoxes;
_checkBoxes = new CheckEdit[] { checkEdit1, checkEdit2, checkEdit3, checkEdit4, checkEdit5, checkEdit6, checkEdit7, checkEdit8, checkEdit9, checkEdit10 };
for (int i = 0; i < _checkBoxes.Length; i++)
{
if (_checkBoxes[i].CheckState == CheckState.Checked)
{
s_question_true++;
Console.WriteLine("gia tri cua s_question_true = {0}", s_question_true);
}
}
trunggian = (float)(s_question_true / 10);
percent = Convert.ToInt32(trunggian * 100);
dexibel = Convert.ToInt32(lbDecibel.Text);
//DialogResult result = MessageBox.Show("Bạn có muốn kết thúc bài Test không?", "Confirmation", MessageBoxButtons.YesNoCancel);
if (check_play == true)
{
if (btnOption.Caption == "Kiểm tra")
{
series1.Points.Add(new SeriesPoint(dexibel, percent));
series1.View.Color = System.Drawing.Color.Red;
this.chartControl1.Series.Add(series1);
((LineSeriesView)series1.View).MarkerVisibility = DevExpress.Utils.DefaultBoolean.True;
((LineSeriesView)series1.View).LineMarkerOptions.Kind = MarkerKind.Circle;
}
}
}