LocalReport - Render Excel returns 0-length byte array RRS feed

  • Question

  • Hello,

    I am using the LocalReport class to generate PDF/Excel files from an RDL.

    In my local development machine, everything works perfectly, PDF and Excel files are rendered with the expected content.

    However, after deploying to the QA server, Excel files are blank, only PDF work as expected. No exceptions are thrown and the Warning array that is populated on the Render() method is empty.

    My guess is that a specific assembly/package is required for Excel creation, and that assembly/package exists on my machine but not on the server.

    Do you guys have any idea if that could be the case and what may be missing?

    Thanks a lot!

    Wednesday, March 9, 2016 8:01 PM

All replies

  • Well, I know this is not the answer you're expecting and certainly not the way I wanted to solve this problem. We tried installing, on the QA server, Report Viewer Runtime, Visual Studio Office Tools and some other packages that I lost track of, and Excel files were still blank.

    Then I thought, why not try generating XLSX instead? So I changed

    var renderedBytes = lr.Render


    var renderedBytes = lr.Render

    and it just worked. Hope this helps someone.


    Monday, March 14, 2016 9:39 AM