the Max of Y Axes is much large,the lines came together.
Posted: Wed Feb 01, 2012 9:29 am
We develop an application in .Net 3.5 in VS 2010 c#, using TeeChart Pro v 3.5.3225.32185.
I had a graph,the tChart1.Axes.Left.Maximum = 4.08426213706027E+304,the lines came together at the bottom of the graph.(1.jpg) But changed to tChart1.Axes.Left.Maximum = 4.08426213706027E+284, it worked properly.
Please help to fix this issue, thanks.
I had a graph,the tChart1.Axes.Left.Maximum = 4.08426213706027E+304,the lines came together at the bottom of the graph.(1.jpg) But changed to tChart1.Axes.Left.Maximum = 4.08426213706027E+284, it worked properly.
Code: Select all
public Form2()
{
InitializeComponent();
this.tChart1.Legend.Visible = false;
this.tChart1.Axes.Left.Automatic = false;
this.tChart1.Axes.Left.Logarithmic = true;
this.tChart1.Axes.Left.LogarithmicBase = 10;
this.tChart1.Axes.Left.Labels.ValueFormat = "0.000E+00";
}
private void Form2_Load(object sender, EventArgs e)
{
this.tChart1.Axes.Left.Maximum = 4.08426213706027E+284;// 4.08426213706027E+304
this.tChart1.Axes.Left.Minimum = 2.8275674035204469E-288;
this.tChart1.Axes.Left.Labels.Items.Add(1);
this.tChart1.Axes.Left.Labels.Items.Add(1E+50);
this.tChart1.Axes.Left.Labels.Items.Add(1E+100);
this.tChart1.Axes.Left.Labels.Items.Add(1E+150);
this.tChart1.Axes.Left.Labels.Items.Add(1E+200);
this.tChart1.Axes.Left.Labels.Items.Add(1E+250);
List<DataTable> dtList = buildDatatable();
this.line1.DataSource = dtList[0];
this.line2.DataSource = dtList[1];
this.line3.DataSource = dtList[2];
this.tChart1.Series.Add(line1);
this.tChart1.Series.Add(line2);
this.tChart1.Series.Add(line3);
}
private List<DataTable> buildDatatable()
{
List<DataTable> dtList = new List<DataTable>();
DataTable dt1 = new DataTable();
dt1.Columns.Add("X", typeof(double));
dt1.Columns.Add("Y", typeof(double));
DataRow dr1 = dt1.NewRow();
dr1[0] = 10;
dr1[1] = 1.39800766563162E-70;
dt1.Rows.Add(dr1);
DataRow dr2 = dt1.NewRow();
dr2[0] = 10;
dr2[1] = 0;
dt1.Rows.Add(dr2);
DataRow dr3 = dt1.NewRow();
dr3[0] = 10;
dr3[1] = 2.00875957481366E-174;
dt1.Rows.Add(dr3);
DataRow dr4 = dt1.NewRow();
dr4[0] = 10;
dr4[1] = 2.11875691981658E-185;
dt1.Rows.Add(dr4);
DataRow dr5 = dt1.NewRow();
dr5[0] = 9;
dr5[1] = 7.46979737092772E-108;
dt1.Rows.Add(dr5);
DataRow dr6 = dt1.NewRow();
dr6[0] = 9;
dr6[1] = 4.52526441797696E-184;
dt1.Rows.Add(dr6);
DataRow dr7 = dt1.NewRow();
dr7[0] = 9;
dr7[1] = 0;
dt1.Rows.Add(dr7);
DataRow dr8 = dt1.NewRow();
dr8[0] = 8;
dr8[1] = 6.38942412474707E-33;
dt1.Rows.Add(dr8);
DataRow dr9 = dt1.NewRow();
dr9[0] = 8;
dr9[1] = 3.40282E+38;
dt1.Rows.Add(dr9);
DataRow dr10 = dt1.NewRow();
dr10[0] = 8;
dr10[1] = 0;
dt1.Rows.Add(dr10);
DataRow dr11 = dt1.NewRow();
dr11[0] = 8;
dr11[1] = 3.40282E+38;
dt1.Rows.Add(dr11);
DataTable dt2 = new DataTable();
dt2.Columns.Add("X", typeof(double));
dt2.Columns.Add("Y", typeof(double));
DataRow dr12 = dt2.NewRow();
dr12[0] = 6.4;
dr12[1] = 4.08426213706027E+304;
dt2.Rows.Add(dr12);
DataRow dr13 = dt2.NewRow();
dr13[0] = 6.85;
dr13[1] = 1.7189571678554E+253;
dt2.Rows.Add(dr13);
DataRow dr14 = dt2.NewRow();
dr14[0] = 7.3;
dr14[1] = 1.01973808521079E+205;
dt2.Rows.Add(dr14);
DataRow dr15 = dt2.NewRow();
dr15[0] = 7.75;
dr15[1] = 5.69372687861038E+160;
dt2.Rows.Add(dr15);
DataRow dr16 = dt2.NewRow();
dr16[0] = 8.2;
dr16[1] = 1.63064051393222E+121;
dt2.Rows.Add(dr16);
DataRow dr17 = dt2.NewRow();
dr17[0] = 8.65;
dr17[1] = 6.02633699220662E+86;
dt2.Rows.Add(dr17);
DataRow dr18 = dt2.NewRow();
dr18[0] = 9.1;
dr18[1] = 2.2430148281314E+57;
dt2.Rows.Add(dr18);
DataRow dr19 = dt2.NewRow();
dr19[0] = 9.55;
dr19[1] = 2.27890359741445E+32;
dt2.Rows.Add(dr19);
DataRow dr20 = dt2.NewRow();
dr20[0] = 10;
dr20[1] = 100158090928.61;
dt2.Rows.Add(dr20);
DataTable dt3 = new DataTable();
dt3.Columns.Add("X", typeof(double));
dt3.Columns.Add("Y", typeof(double));
DataRow dr21 = dt3.NewRow();
dr21[0] = 1;
dr21[1] = 1.16358004861699E+82;
dt3.Rows.Add(dr21);
DataRow dr22 = dt3.NewRow();
dr22[0] = 1.45;
dr22[1] = 2.18570166198165E+72;
dt3.Rows.Add(dr22);
DataRow dr23 = dt3.NewRow();
dr23[0] = 1.9;
dr23[1] = 2.73310532655426E+62;
dt3.Rows.Add(dr23);
DataRow dr24 = dt3.NewRow();
dr24[0] = 2.35;
dr24[1] = 2.09903561209854E+52;
dt3.Rows.Add(dr24);
DataRow dr25 = dt3.NewRow();
dr25[0] = 2.8;
dr25[1] = 8.93834056380673E+41;
dt3.Rows.Add(dr25);
DataRow dr26 = dt3.NewRow();
dr26[0] = 3.25;
dr26[1] = 1.85036669017211E+31;
dt3.Rows.Add(dr26);
DataRow dr27 = dt3.NewRow();
dr27[0] = 3.7;
dr27[1] = 1.5691929836259E+20;
dt3.Rows.Add(dr27);
DataRow dr28 = dt3.NewRow();
dr28[0] = 4.15;
dr28[1] = 434981707.291244;
dt3.Rows.Add(dr28);
DataRow dr29 = dt3.NewRow();
dr29[0] = 4.6;
dr29[1] = 0.00029153678812653;
dt3.Rows.Add(dr29);
DataRow dr30 = dt3.NewRow();
dr30[0] = 5.05;
dr30[1] = 3.14330332192612E-17;
dt3.Rows.Add(dr30);
DataRow dr31 = dt3.NewRow();
dr31[0] = 5.5;
dr31[1] = 3.12790790490833E-31;
dt3.Rows.Add(dr31);
DataRow dr32 = dt3.NewRow();
dr32[0] = 5.95;
dr32[1] = 1.34315248213562E-46;
dt3.Rows.Add(dr32);
DataRow dr33 = dt3.NewRow();
dr33[0] = 6.4;
dr33[1] = 8.85885079861335E-64;
dt3.Rows.Add(dr33);
DataRow dr34 = dt3.NewRow();
dr34[0] = 6.85;
dr34[1] = 2.28577135947854E-83;
dt3.Rows.Add(dr34);
DataRow dr35 = dt3.NewRow();
dr35[0] = 7.3;
dr35[1] = 4.18423481557931E-106;
dt3.Rows.Add(dr35);
DataRow dr36 = dt3.NewRow();
dr36[0] = 7.75;
dr36[1] = 8.13794788072479E-133;
dt3.Rows.Add(dr36);
DataRow dr37 = dt3.NewRow();
dr37[0] = 8.2;
dr37[1] = 3.08574584486458E-164;
dt3.Rows.Add(dr37);
DataRow dr38 = dt3.NewRow();
dr38[0] = 8.65;
dr38[1] = 9.06717115881249E-201;
dt3.Rows.Add(dr38);
DataRow dr39 = dt3.NewRow();
dr39[0] = 9.1;
dr39[1] = 2.64545226449627E-242;
dt3.Rows.Add(dr39);
DataRow dr40 = dt3.NewRow();
dr40[0] = 9.55;
dr40[1] = 2.82756740352045E-288;
dt3.Rows.Add(dr40);
DataRow dr41 = dt3.NewRow();
dr41[0] = 10;
dr41[1] = 0;
dt3.Rows.Add(dr41);
dtList.Add(dt1);
dtList.Add(dt2);
dtList.Add(dt3);
return dtList;
}