Jump to content
Software FX Community

atesfay1

Members
  • Posts

    6
  • Joined

  • Last visited

atesfay1's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. Hi, Thanks for the quick response. You can actually recreate this problem by using one of the sample applications provided by ChartFx ( [installation Path]\Chart FX 7\Help and Samples\Sample Applications\Web Forms\VS2005\WorldPopulation ). Set the width and height of Chart1 to 8000 and try to Chart1.Export( FileFormat.Png, @"C:\temp\worldpopulation.png");You should get the following stack trace error: at System.Drawing.Bitmap..ctor(Int32 width, Int32 height, PixelFormat format) at System.Drawing.Bitmap..ctor(Int32 width, Int32 height) at ChartFX.WebForms.Internal.v.a(Graphics A_0, Int32 A_1, Int32 A_2) at ChartFX.WebForms.Chart.n() at ChartFX.WebForms.Chart.cp() at ChartFX.WebForms.Annotation.AnnotationList.a(IGraphicsEx A_0, Rectangle A_1, Boolean A_2, Boolean A_3, Int32 A_4, Int32 A_5) at ChartFX.WebForms.Annotation.Annotations.a(IGraphicsEx A_0, Rectangle A_1, Boolean A_2, Int32 A_3, Int32 A_4) at ChartFX.WebForms.Maps.MapGallery.a(PaintMarkBase A_0, Rectangle A_1, Int32 A_2, Int32 A_3) at ChartFX.WebForms.Maps.MapGallery.a(Int32 A_0, PaintMarkBase A_1, Int32& A_2, Int32& A_3) at ChartFX.WebForms.u.a(Int32& A_0, Int32& A_1) at ChartFX.WebForms.u.r() at ChartFX.WebForms.u.a(IFrame A_0, Int32& A_1) at ChartFX.WebForms.Chart.a(PaintBar A_0, IGraphicsEx A_1) at ChartFX.WebForms.Chart.a(PaintBar A_0, IGraphicsEx A_1, Rectangle& A_2) at ChartFX.WebForms.Chart.a(IGraphicsEx A_0, Rectangle A_1, Boolean A_2) at ChartFX.WebForms.Chart.a(Stream A_0, IOutputWriter A_1, OutputText A_2, OutputText A_3, OutputInfo A_4) at ChartFX.WebForms.Chart.a(String A_0, Stream A_1, TextWriter A_2, TextWriter A_3) at ChartFX.WebForms.Chart.Export(FileFormat format, Stream stream) at ChartFX.WebForms.Chart.Export(FileFormat format, String fileName) The width and height value thresholds that cause this error varies from svg to svg. Thanks
  2. Hi, A Map created with the following specification for the US-States SVG crashes. ... map1 .Chart.AllSeries.PointLabels.Font = new Font("Arial", 8, FontStyle.Regular);map1.Chart.Width = 6000; map1.Chart.Height = 6000; map1.Chart.Export( FileFormat.png, sPath); Note: For an SVG file that has longer geography titles, the width and height specification don't have to be this large for it to break. The stack trace of the error is as follows: "System.Web.Services.Protocols.SoapException: Server was unable to process request. ---> System.ArgumentException: Parameter is not valid.\r\n at System.Drawing.Bitmap..ctor(Int32 width, Int32 height, PixelFormat format)\r\n at System.Drawing.Bitmap..ctor(Int32 width, Int32 height)\r\n at ChartFX.WebForms.Internal.v.a(Graphics A_0, Int32 A_1, Int32 A_2)\r\n at ChartFX.WebForms.Chart.n()\r\n at ChartFX.WebForms.Chart.cp()\r\n at ChartFX.WebForms.Annotation.AnnotationText.SizeToFit()\r\n at ChartFX.WebForms.Annotation.AnnotationText.set_Font(Font value)\r\n at ChartFX.WebForms.Maps.MapGallery.a(MapElement A_0, AnnotationText A_1, AttributesBase A_2, Int32 A_3, Boolean A_4, Boolean A_5)\r\n at ChartFX.WebForms.Maps.MapGallery.b(MapElement A_0, AttributesBase A_1)\r\n at ChartFX.WebForms.Maps.MapGallery.d(MapElement A_0)\r\n at ChartFX.WebForms.Maps.MapElementCollection.b()\r\n at ChartFX.WebForms.Maps.MapGallery.e(Int32 A_0)\r\n at ChartFX.WebForms.Maps.MapGallery.f(Boolean A_0)\r\n at ChartFX.WebForms.Maps.MapGallery.a(Int32 A_0, PaintMarkBase A_1, Int32& A_2, Int32& A_3)\r\n at ChartFX.WebForms.u.r()\r\n at ChartFX.WebForms.u.a(IFrame A_0, Int32& A_1)\r\n at ChartFX.WebForms.Chart.a(PaintBar A_0, IGraphicsEx A_1)\r\n at ChartFX.WebForms.Chart.a(PaintBar A_0, IGraphicsEx A_1, Rectangle& A_2)\r\n at ChartFX.WebForms.Chart.a(IGraphicsEx A_0, Rectangle A_1, Boolean A_2)\r\n at ChartFX.WebForms.Chart.a(Stream A_0, IOutputWriter A_1, OutputText A_2, OutputText A_3, OutputInfo A_4)\r\n at ChartFX.WebForms.Chart.a(String A_0, Stream A_1, TextWriter A_2, TextWriter A_3)\r\n at ChartFX.WebForms.Chart.Export(FileFormat format, Stream stream)\r\n at ChartFX.WebForms.Chart.Export(FileFormat format, String fileName)\r\n ... --- End of inner exception stack trace ---" Thanks for your help
  3. It works! I should not have used the RenderControl method of the Map object. Thanks for all your help!
  4. Frank, Thanks again for the quick reply. Yes, I had skipped the portion that assigns a MapSource and data (two dimensional object array) in the post but it is being done. How should I get the "full project" to you? Thanks.
  5. Hi Frank, Thanks for the quick reply. Unfortunately, I had tried both options. By the way, what do you mean by "Map extension is attached"? Option 1++++ map1 = new Map(); chart1 = new Chart(); map1.Chart = chart1; ... StringBuilder sb = new StringBuilder(); StringWriter oStringWriter = new StringWriter(sb);System.Web.UI.HtmlTextWriter oWriter = new System.Web.UI.HtmlTextWriter(oStringWriter); map1.RenderControl(oWriter);return sb.ToString(); ++++ sb.ToString() was empty. Option 2+++++++ chart1.Export( FileFormat.Png, "C:\temp\map.png") returned a regular Line Chart. using one of the samples that came with the installation, I was able to find that the Map gallery corresponds to 29959, so I tried the following: chart1.Gallery = (Gallery)29959; chart1.Export( FileFormat.Png, "C:\temp\map.png") In this case, I was able to get a Map output but it didn't have the SVG geography labels, not to mention this hack will break as soon as the internal representation of the Map gallery changes to a different integer. +++++++ Thanks for all your help.
  6. Hi, In ChartFX 6.2, I export a Map that contains the underlying data along with the ConditionalAttributes using the GetHtmlTag() method. In ChartFX 7, I wasn't able to find a method that performs this operation. None of the Export methods of the underlying Chart class (it looks likethe Map class now has a Chart object as a member instead of inheriting from the Chart class), were able to export the "processed" SVG file (i.e. the equivalent of the output of the GetHtmlTag() method in ChartFX 6.2). Please help. Thanks
×
×
  • Create New...