Link to home
Start Free TrialLog in
Avatar of andyw27
andyw27

asked on

Opening Resource file into Filestream

Hi,

I’ve added a file as a resource to a project.  The file is an Excel document.

I’m trying to use this within the ASPose Cells framework.  Their documentation states it can open a file from a file stream.  However I’m at a complete loss as to how to get from a resource to a file stream?

Does anybody have any snippets they could share?

Here is the code that I have:

//Create a Stream object
FileStream fstream = new FileStream("C:\\book1.xls", FileMode.Open);

//Creating a Workbook object, open the file from a Stream object
//that contains the content of file and it should support seeking
Workbook workbook = new Workbook(fstream);

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Éric Moreau
Éric Moreau
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial