Coder Social home page Coder Social logo

devexpress-examples / reporting_web-document-viewer-how-to-send-a-report-via-email-from-the-client-side-t566760 Goto Github PK

View Code? Open in Web Editor NEW
1.0 56.0 1.0 3.06 MB

How to email a report in a web reporting application.

License: Other

C# 45.78% HTML 5.55% ASP.NET 0.39% Visual Basic .NET 48.29%
asp-net-mvc email export mail-kit reporting web-reporting xtrareport reporting-for-mvc

reporting_web-document-viewer-how-to-send-a-report-via-email-from-the-client-side-t566760's Introduction

Reporting for ASP.NET MVC - How to Email a Report from the Document Viewer

This example adds a custom action button to the Document Viewer that triggers a custom operation on the server side. The server-side custom operation exports a report to HTML and PDF, and emails the resulting documents.

When you run the application, you observe the Document Viewer with a newly added action button:

Document Viewer with a Custom Button to Email a Report

To email a report, click the button. The application attempts to send email to [email protected] using the localhost SMTP server, port 25. Modify the code to apply your mail server settings.

The report sent by email is shown in the following image:

Report Sent by Email

When the user clicks the 'Send via Email' button, the client-side PerformCustomDocumentOperation method passes data to the DocumentOperationService on the server. The service exports the report to PDF and HTML formats, creates the MIME message and sends email using the MailKIt client.

The PerformCustomDocumentOperation method returns an object that implements the IDocumentOperationResult interface, so you can return the data from the DocumentOperationService to the client.

Files to Review

Documentation

More Examples

reporting_web-document-viewer-how-to-send-a-report-via-email-from-the-client-side-t566760's People

Contributors

andreylepikhov avatar devexpressexamplebot avatar pollyndos avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

oagsate

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.