title: ASP.NET MVC - How to obtain file from FileResult?
body: <p>Short version:
  I have a third-party MVC Extension that returns the FileResult. I would like to be able to process the file before returning it to the client. How can I do that?</p>
  
  <p>If you're interested in boring details, read below:</p>
  
  <p>I'm using Devexpress XtraReports for reporting purposes. The problem is that it's PDF Export is terrible, but RTF one works great. I would like to create action&amp;result filter that would  trick DevExpress into generating rtf instead of pdf (done) and convert the rtf to pdf using some other third-party library. The only problem is that I need to obtain rtf file from FileResult and return my own FileResult with the converted content.</p>
  
  <p>//EDIT:
  The code right now looks as follows:</p>
  
  <pre><code>        public virtual ActionResult ReportExport(TParameters parameters)
          {
              return DevExpress.Web.Mvc.ReportViewerExtension.ExportTo(this.GetReport(parameters));    
          }
  </code></pre>