Cannot access file, being used by another process

Technical support for Spire.XLS

Moderators: iceblue support, Flash, Manager

Cannot access file, being used by another process

Postby condornwmsn » Wed Feb 20, 2013 5:08 pm


I am migrating to generate reports in a web-service and am having a strange problem that occurs sometimes, other times not, file is ok.

Apparently the Spire.XLS is keeping the file in use after closing, and the result is a corrupted file.

20 times reapeting same operation, at least about 5 this kind of problem occurs.

I'm using version

I tried to migrate to the latest version which I am entitled, but there was another problem with special characters, as well as the problem of file in use also occurred.

What can I do?
Posts: 4
Joined: Tue Sep 13, 2011 9:53 pm

Re: Cannot access file, being used by another process

Postby amy.zhao » Thu Feb 21, 2013 7:15 am


Thanks for your inquiry.
Please try the solution below to load your excel document.
Code: Select all
              using (Workbook workbook = new Workbook())
                        byte[] bytes = File.ReadAllBytes(excelfilePath);
                        using (Stream stream = new MemoryStream(bytes))

Please tell us if you still have the problem after try the code above.

Best Regards,
E-iceblue support team
User avatar
Posts: 2229
Joined: Wed Jun 27, 2012 8:50 am

Return to Spire.XLS

Who is online

Users browsing this forum: No registered users and 1 guest