Difference between TeeChart 5 and TeeChart 2011
Difference between TeeChart 5 and TeeChart 2011
Hi,
my company integrated from VB to C# and these differences are really important to me, because it can change the whole behavior of the software.
our software is clinical software that serves physicians and nurses, so every pixel difference or a small change can count.
i made some sample project in VB and NET and i'm trying to understand the differences between the two.
in these samples, there are charts with similar configuration. when you press the button, the textbox text filled up with the first five points of the left axis(see the sample code for more information - it is really simple).
i get different values in VB and .NET, and the behavior of the bars(without SideMargins) is not the same.
my target is to get the .NET chart to behave like the VB one.
we have other problems in our application, i'm still trying to reproduce it in a side project.
some of the problems can be fixed when i set the MinimumOffset and MaximumOffset of the axes. What is the difference from VB?
P.S
Can i serialize the chart to a file and load it configuration in another project? it may help me to pass some problems to you.
my company integrated from VB to C# and these differences are really important to me, because it can change the whole behavior of the software.
our software is clinical software that serves physicians and nurses, so every pixel difference or a small change can count.
i made some sample project in VB and NET and i'm trying to understand the differences between the two.
in these samples, there are charts with similar configuration. when you press the button, the textbox text filled up with the first five points of the left axis(see the sample code for more information - it is really simple).
i get different values in VB and .NET, and the behavior of the bars(without SideMargins) is not the same.
my target is to get the .NET chart to behave like the VB one.
we have other problems in our application, i'm still trying to reproduce it in a side project.
some of the problems can be fixed when i set the MinimumOffset and MaximumOffset of the axes. What is the difference from VB?
P.S
Can i serialize the chart to a file and load it configuration in another project? it may help me to pass some problems to you.
- Attachments
-
- TChartNet.rar
- (15.88 KiB) Downloaded 433 times
-
- TChartVBTest.rar
- (1.86 KiB) Downloaded 425 times
Re: Difference between TeeChart 5 and TeeChart 2011
addition:
i succeeded to export the tchart to a *.ten file, so i can send you some of our configuration.
you can load it and reproduce this problem:
i have some space between the first bar and the start of the chart, even though SideMargins in false.
if i change MinimumOffset or MaximumOffset of Bottom axis from 0 to another value, the first bar "jumps" to the start.
why it doesn't starts from the start of the chart with 0 value?
attached: chart configuration with data.
i succeeded to export the tchart to a *.ten file, so i can send you some of our configuration.
you can load it and reproduce this problem:
i have some space between the first bar and the start of the chart, even though SideMargins in false.
if i change MinimumOffset or MaximumOffset of Bottom axis from 0 to another value, the first bar "jumps" to the start.
why it doesn't starts from the start of the chart with 0 value?
attached: chart configuration with data.
- Attachments
-
- graph_with_data.rar
- (2.84 KiB) Downloaded 419 times
Re: Difference between TeeChart 5 and TeeChart 2011
Hello MVuser2,
Thanks,
Ok. First you use to check the behavior, two different products of TeeChart and is possible as you find differences of behavior, and is the case of FillSampleValues the values are generated are different, so its function is added a sample of random values. If you want achieve the same values in the both versions, I recommend you add manually the values with Series.Add method.in these samples, there are charts with similar configuration. when you press the button, the textbox text filled up with the first five points of the left axis(see the sample code for more information - it is really simple).i get different values in VB and .NET, and the behavior of the bars(without SideMargins) is not the same.my target is to get the .NET chart to behave like the VB one.
You can solve your problem setting property InflateMargins of Marks to true as do in next line of code:we have other problems in our application, i'm still trying to reproduce it in a side project.
some of the problems can be fixed when i set the MinimumOffset and MaximumOffset of the axes. What is the difference from VB?
Code: Select all
Steema.TeeChart.Styles.Bar bar;
Steema.TeeChart.Styles.Line line;
private void Form1_Load(object sender, EventArgs e)
{
tChart1.Clear();
tChart1.Series.Clear();
tChart1.Aspect.View3D = false;
bar = new Steema.TeeChart.Styles.Bar(tChart1.Chart);
bar.FillSampleValues(10);
bar.SideMargins = false;
line = new Steema.TeeChart.Styles.Line(tChart1.Chart);
line.DataSource = bar;
bar.Marks.InflateMargins = false;
line.RefreshSeries();
// bar.Marks.Visible = false;
//Axes;
tChart1.Axes.Left.SetMinMax(0, 28);
// tChart1.Axes.Left.MaximumOffset = 1;
tChart1.Axes.Bottom.SetMinMax(0, 9);
tChart1.Walls.Back.Visible = false;
tChart1.Draw();
}
I can not reproduce your problem, can you please attached an image where you indicate the exactly problem, because we can try to find a good solution for you? On the other hand, can you tell us which version of TeeChartFor.Net are you using now?i have some space between the first bar and the start of the chart, even though SideMargins in false.
if i change MinimumOffset or MaximumOffset of Bottom axis from 0 to another value, the first bar "jumps" to the start.
why it doesn't starts from the start of the chart with 0 value?
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Difference between TeeChart 5 and TeeChart 2011
i'm using TeeChart version 4.1.2011.6283.
InflateMargins didn't solve me problem.
i posted two screenshots for you to understand the offset problems.
you can load the same chart configuration and data from the file above in my last message(graph_with_data.rar).
when MinimumOffset and MaximumOffset of an axis is 0, there is a strange space.
i cannot reproduce this behavior in VB because there is no MinimumOffset and MaximumOffset there.
i'm trying to understand if there is another way cope with this difference instead of setting offsets, because i'm getting different behavior in VB and .NET application.
InflateMargins didn't solve me problem.
i posted two screenshots for you to understand the offset problems.
you can load the same chart configuration and data from the file above in my last message(graph_with_data.rar).
when MinimumOffset and MaximumOffset of an axis is 0, there is a strange space.
i cannot reproduce this behavior in VB because there is no MinimumOffset and MaximumOffset there.
i'm trying to understand if there is another way cope with this difference instead of setting offsets, because i'm getting different behavior in VB and .NET application.
Re: Difference between TeeChart 5 and TeeChart 2011
Hello MVuser2,
Ok, thanks for the information. Checking your code, I have found where the problem is and I think you can solve it if you change the value of OffsetPercent of the Bar Series as do in next lines of code:
Can you tell us if previous code help you to solve your problem?
On the other hand, I inform you that you there are a newest maintenace releases of TeeChartFor.Net and I recommend you update your version. You can download it in the customer page
I hope will helps.
Thanks,
Ok, thanks for the information. Checking your code, I have found where the problem is and I think you can solve it if you change the value of OffsetPercent of the Bar Series as do in next lines of code:
Code: Select all
private void button3_Click(object sender, EventArgs e)
{
tChart1.Series.Clear();
tChart1.Import.Template.Load(@"C:\Users\Sandra\Downloads\graph_with_data\graph_with_data.ten");
(tChart1[2] as Steema.TeeChart.Styles.Bar).OffsetPercent = 10;
}
On the other hand, I inform you that you there are a newest maintenace releases of TeeChartFor.Net and I recommend you update your version. You can download it in the customer page
I hope will helps.
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Difference between TeeChart 5 and TeeChart 2011
Thanks Sandra,
Here is another question:
Can you check if InflateMargins behave differently in VB and .NET?
in our application, both .NET and VB, it is set to true, but in .NET in some places we need to set offsets or cancel it.
Here is another question:
Can you check if InflateMargins behave differently in VB and .NET?
in our application, both .NET and VB, it is set to true, but in .NET in some places we need to set offsets or cancel it.
Re: Difference between TeeChart 5 and TeeChart 2011
Hello MVuser2,
Thanks,
Marks.InflateMargins property doesn't exist in VB, so is a property of TeeChartFor.Net that expands axes to fit Series Marks. Some properties are implemented in the TeeChartFor.Net to draw the chart more elegant. As I have told you are comparing two different products of TeeChart and is possible as you find differences of behavior and probably you need add or modified your code to achieve a same results in both products.Can you check if InflateMargins behave differently in VB and .NET?
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Difference between TeeChart 5 and TeeChart 2011
Hi Sandra,
thanks for your help.
i understand that the behavior is not the same and i want to do the perfect solution.
for now on, i know that i can use MinimumOffset and MaximumOffset to align the axes and InflateMargins of series to make sure that it won't change axes original location.
are there any other properties of series that affects the positioning of the axes?
are there any other properties that affects the offsets of the axes?
thanks for your help.
i understand that the behavior is not the same and i want to do the perfect solution.
for now on, i know that i can use MinimumOffset and MaximumOffset to align the axes and InflateMargins of series to make sure that it won't change axes original location.
are there any other properties of series that affects the positioning of the axes?
are there any other properties that affects the offsets of the axes?
Re: Difference between TeeChart 5 and TeeChart 2011
Hello MVuser2,
At the moment, I don't have any ideas at mind about other properties of Series can affects to the axes apart from of Marks.InflateMargins, Points.InflateMargins or Offset.
Thanks,
At the moment, I don't have any ideas at mind about other properties of Series can affects to the axes apart from of Marks.InflateMargins, Points.InflateMargins or Offset.
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |