Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
20
Unable to load .xlsm file in .Net Standard 2.0 Project with Exception - Invalid or unrecognized file format. (Parameter 'stream')
posted

Trying to load a xlsm file in the workbook using --> 

Workbook.Load(fileStream);

Getting an exception - Invalid or unrecognized file format. (Parameter 'stream')

This is a dot net standard 2.0 project. The same line of code works fine in a .net framework 4.6 project. 

Any ideas on what can be the issue ?

Parents
No Data
Reply
  • 20
    Offline posted

     I even tried a one liner code Workbook.Load(fileStream); within a .net framework 4.6.1 app and a dot net core 3.1 app but the dot net core failed to fetch the xlsm file.

Children