Export Image border

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Hermes
Newbie
Newbie
Posts: 5
Joined: Wed May 23, 2018 12:00 am

Export Image border

Post by Hermes » Mon Jan 07, 2019 7:38 pm

Hi, I have a problem when exporting a graphic to an image, the border even though it does not have it, it appears in the exported image.
I send attached the two images as an example.
The code:
mGrafico.Chart.Export.Image.JPEG.Height = vAlto;
mGrafico.Chart.Export.Image.JPEG.Width = vAncho;
mGrafico.Chart.Export.Image.JPEG.Quality = 100;

I'm using TeeChart 2018 web forms.

Regards
Attachments
ErrorExportImagen_Result.png
ErrorExportImagen_Result.png (365.25 KiB) Viewed 8607 times
ErrorExportImagen_Orig.png
ErrorExportImagen_Orig.png (72.5 KiB) Viewed 8607 times

Christopher
Guru
Posts: 1603
Joined: Fri Nov 15, 2002 12:00 am

Re: Export Image border

Post by Christopher » Tue Jan 08, 2019 7:40 am

Hello,
Hermes wrote:
Mon Jan 07, 2019 7:38 pm
Hi, I have a problem when exporting a graphic to an image, the border even though it does not have it, it appears in the exported image.
You should be able to eliminate this border by setting the Graphics3D.BufferStyle property to None, e.g.

Code: Select all

			var oldStyle = tChart1.Graphics3D.BufferStyle;

			tChart1.Graphics3D.BufferStyle = Steema.TeeChart.Drawing.BufferStyle.None;

			var jpeg = tChart1.Export.Image.JPEG;

			jpeg.Quality = 100;
			jpeg.Height = 300;
			jpeg.Width = 600;

			jpeg.Save(@"C:\tmp\chart2.jpeg");

			tChart1.Graphics3D.BufferStyle = oldStyle;

Best Regards,
Christopher Ireland / 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

Hermes
Newbie
Newbie
Posts: 5
Joined: Wed May 23, 2018 12:00 am

Re: Export Image border

Post by Hermes » Wed Jan 09, 2019 7:19 pm

Hi, it works fine.
thank you

Post Reply