Hi Steema,
We want to save the single image of Multiple opened charts in different tiled windows as shown in image. as shown in attached image
Please provide any solution asap.
Thanks in advance.
Thanks&Regards
Plano Research
Save Image of Multiple Chart
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Save Image of Multiple Chart
Hello!
This isn't really a TeeChart issue per se, as TeeChart is perfectly capable of exporting itself to an image.
If you want to combine two (or more) images to one image, you can create a new bitmap then paint each image onto it. First create a bitmap at runtime, then create the graphics from the image and then use this graphics to draw your images to it.
This isn't really a TeeChart issue per se, as TeeChart is perfectly capable of exporting itself to an image.
If you want to combine two (or more) images to one image, you can create a new bitmap then paint each image onto it. First create a bitmap at runtime, then create the graphics from the image and then use this graphics to draw your images to it.
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 |
Re: Save Image of Multiple Chart
Hi
We are creating a application in window form conatins a panel and Panel contains Teechart and few textboxes and labels. We are trying to implement functionality "save as image" of all contents of panel. All contents saved as image but teechart is not exported as image. We are using this code below:
using (Bitmap bitmap = new Bitmap(panel2.ClientSize.Width,
panel2.ClientSize.Height))
{
panel2.DrawToBitmap(bitmap, panel2.ClientRectangle);
bitmap.Save(deskTopPath + @"/snap_" + snapCount.ToString() + @".png", ImageFormat.Png);
}
How to achive this functionality?
Please reply soon.
Thanks
Plano
We are creating a application in window form conatins a panel and Panel contains Teechart and few textboxes and labels. We are trying to implement functionality "save as image" of all contents of panel. All contents saved as image but teechart is not exported as image. We are using this code below:
using (Bitmap bitmap = new Bitmap(panel2.ClientSize.Width,
panel2.ClientSize.Height))
{
panel2.DrawToBitmap(bitmap, panel2.ClientRectangle);
bitmap.Save(deskTopPath + @"/snap_" + snapCount.ToString() + @".png", ImageFormat.Png);
}
How to achive this functionality?
Please reply soon.
Thanks
Plano
Re: Save Image of Multiple Chart
Hi Team,
A demo project is attached of above mail. Please find.
Thanks
Plano Team
A demo project is attached of above mail. Please find.
Thanks
Plano Team
- Attachments
-
- WindowsFormsApplication1.rar
- Demo Project
- (134.73 KiB) Downloaded 742 times
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Save Image of Multiple Chart
This seems to be a limitation of the Control.DrawToBitmap Method:amol wrote: A demo project is attached of above mail. Please find.
If DrawToBitmap cannot even render Microsoft's own controls such as RichTextBox, then I'm afraid it doesn't surprise me that TeeChart is not being rendered.The DrawToBitmap method is not supported for ActiveX controls. You can override the OnPrint event and provide custom printing logic if required.
The DrawToBitmap method has the following limitations:
An ArgumentException might be thrown for large bitmaps. The maximum allowable size varies by machine.
DrawToBitmap does not support the Ink controls for the Windows XP Tablet PC Edition 2005 operating system.
DrawToBitmap does not draw a child TextBox if the Visible property of the TextBox is set to false.
Controls inside containers are rendered in reverse order.
DrawToBitmap is not fully functional for the RichTextBox; only the border of a bitmap is drawn.
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 |
Re: Save Image of Multiple Chart
Hi Steema,
Please provide me the solution for that.
Thanks
Plano
Please provide me the solution for that.
Thanks
Plano
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Save Image of Multiple Chart
I think I have already suggested a solution to this issue in my post here:amol wrote: Please provide me the solution for that.
Code: Select all
If you want to combine two (or more) images to one image, you can create a new bitmap then paint each image onto it. First create a bitmap at runtime, then create the graphics from the image and then use this graphics to draw your images to it.
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 |
Re: Save Image of Multiple Chart
Hi Steema
Please create a sample application.
Thanks
Plano
Please create a sample application.
Thanks
Plano
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Save Image of Multiple Chart
With all due respect, I feel this is a generic programming issue and not one specific to either the TeeChart API or the TeeChart source code.amol wrote: Please create a sample application.
May I suggest that you make the first attempt at this, and if you are unsuccessful then please post your code here so that I can help you with it.
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 |