12. April 2013

Create a PDF file on button press in browser

When you use the FastReport .Net together ASP.Net MVC framework you have easy method for creating file in any supported format on button press in HTML form.

Add next code in View:

 @using (Html.BeginForm("GetFile", "Home"))
 {
         <input id="pdf" type="submit" value="Export to PDF" />
 }

GetFile - name of controller handler, Home - name of controller (HomeController.cs for example)

Add name space in controller: more...

Fast Reports
  • 800-985-8986 (Englisch, die USA)
  • +4930568373928 (Deutsch)
  • +55 19 98147-8148 (Portugiesisch)
  • info@fast-report.com
  • 901 N Pitt Str #325 Alexandria VA 22314

© 1998-2024 Fast Reports Inc.
Trustpilot