案例:将panelEx2保存为png图片
string chartUrl = System.AppDomain.CurrentDomain.SetupInformation.ApplicationBase + @"Chart_d" + velocityId + ".png"; Bitmap bmp = new Bitmap(panelEx2.Width, panelEx2.Height, System.Drawing.Imaging.PixelFormat.Format24bppRgb); panelEx2.DrawToBitmap(bmp, new Rectangle(0, 0, panelEx2.Width, panelEx2.Height)); bmp.Save(chartUrl, System.Drawing.Imaging.ImageFormat.Png);
将 Steema.TeeChart.TChart 保存为图片
string chartUrl = @".Chart_d" + velocityId + ".png"; tChart1.Export.Image.PNG.Save(chartUrl); //保存为png格式;
....