Excel Save Method


#1

After I call the Save method, I can’t use the System.IO.StreamReader to open the file. It saids the file is being used by another process. How do I kill the aspose process?


#2

Could you send me your code about this issue? And have you tried the latest hotfix at http://www.aspose.com/Products/Aspose.Excel/Fixes/Aspose.Excel.zip?


#3

I’ve tried the lastest fix and it still does not work. Below is the code.
-------------------------------------------------------------------



x.Save(fileName, FileFormatType.Excel2000)

Dim reader As System.IO.StreamReader
Dim tokens As String()

reader = New System.IO.StreamReader(filename)

Do While reader.Peek() >= 0
tokens = System.Text.RegularExpressions.Regex.Split(reader.ReadLine(), vbTab)Loop


#4

I tried the following code and all worked fine.

Dim excel As Excel = New Excel()
excel.Worksheets(0).Cells("A1").PutValue("save")
excel.Save("d:\\abc.xls", Aspose.Excel.FileFormatType.Excel2000)

Dim reader As System.IO.StreamReader = New System.IO.StreamReader("d:\\abc.xls")

Dim tokens As String()
Do While reader.Peek() >= 0
tokens = System.Text.RegularExpressions.Regex.Split(reader.ReadLine(), vbTab)
Loop


Please try my code in your machine to see if the exception still occurs.

Which line of code throws the exception in your code?