DayPilot for ASP.NET - AJAX Calendar/Scheduling Controls
Try the online demo: AJAX-style event creating, moving, resizing, and deleting • Context menu • Day view • Work week view • Week view • Month view • Horizontal/vertical resources view • PostBack/AJAX/JavaScript event handling • Binding to XmlDataSource, SqlDataSource, DataTable, ArrayList • Custom event formatting • UpdatePanel compatibility

Image Export (BMP, PNG, GIF, JPG)

It is possible to export the Scheduler into several image formats:

  • BMP
  • GIF
  • JPEG
  • PNG
  • TIFF

Usage

Call DayPilotScheduler.Export() method:

MemoryStream img = DayPilotScheduler1.Export(ImageFormat.Png);

Applications

  • Print the exported image reliably.
  • Save the exported image to a file.
  • Non-web applications:
    • Show a read-only calendar in WebForm applications
    • Include a Scheduler snapshot in PDF files generated on the server
    • Include a Scheduler snapshot in generated e-mails

Limitations

Some limitations apply:

  • The related CSS classes are ignored (CssClassPrefix)
  • It's not possible to use HTML in Before*Render events. You can detect the export by checking DayPilotScheduler.IsExport property and set e.InnerHTML to plain text during export.

Example

This example returns the current Scheduler view as PNG image (it forces the Open/Download dialog box by setting "content-disposition" HTTP header).

protected void ButtonExport_Click(object sender, EventArgs e)
{
  setDataSourceAndBind();
 
  Response.Clear();
  Response.ContentType = "image/png";
  Response.AddHeader("content-disposition", "attachment;filename=print.png");
  MemoryStream img = DayPilotScheduler1.Export(ImageFormat.Png);
  img.WriteTo(Response.OutputStream);
  Response.End();
}

Available Since

DayPilot Pro is an advanced DayPilot edition. You can check a thumbnail overview of the most interesting features. There is also an online demo with all the features working (including the AJAX features). If you want to test the design-time support and API you can download a fully functional trial version. And if you like it, you can buy a full version with source code and 12 months of upgrades and support (with a 30-days money back guarantee).

DayPilot Lite is a do-it-yourself open-source edition of DayPilot. Although it misses some DayPilot Pro features, there are thousands of developers using it to build calendar, personal scheduling, and resource booking applications.