Super 2d/3d Graph Library

Enhance your .NET application adding nice charts within minutes! Save time and money!


Example 18: Realtime PDF export from a web application

This example illustrates how to create PDF file with a nice chart on the fly a web browser. No temporary files are involved.

Hint: this is a great and easy way to print your charts !!

 

Steps:

1. Create a new ASP.NET application project (C#)

2. Add a reference to Super 2d/3d Graph Library and to System.Windows.Forms (this one is necessary for the library to operate on web environments)

3. Insert the following code in the Page_Load event.

4. Run!


Form Code

Insert this code in the Page_Load event:

   Super2d3dGraphLibrary.Super2d3dGraph oGraph = new Super2d3dGraphLibrary.Super2d3dGraph();
   oGraph.LicenseeIdentifier =
"PROF";

   // Create a quick and random sample chart
   oGraph.SampleChart();

   // Increase resolution of chart (great for printing!)
   oGraph.Resolution = 150;

   // Paint the chart
   oGraph.RefreshChart();

   // Output the chart to the browser
   Response.Clear();
   Response.ContentType =
"Application/pdf";
   byte[] pdf = oGraph.CreatePDF(Super2d3dGraphLibrary.STYLE_ORIENTATION.ORIENTATION_LANDSCAPE, 75, true);
   Response.OutputStream.Write(pdf, 0, pdf.Length);


Result:


 

License & Purchase Info


Current version: 14

Super 2d/3d Graph Library is available as:
-Standard License (99€)
-Premium License (149€)
-Enterprise License (299€)

Click here for more details & purchase

Contact Info


Feel free to contact us
for questions related to any of our products or custom .Net development. We usually respond in the same labor day.

Software Siglo XXI

Main support service: support@softwaresigloxxi.com

Sales and other enquiries: contact@softwaresigloxxi.com