in my project I need to save user customized excel to .mht file and immediately reload the file into memory, code is following
var app = new Excel.Application();
var wsCurrent = app.ActiveWorkbook.ActiveSheet;
object format = Excel.XlFileFormat.xlWebArchive;
var codename = application.ActiveSheet.CodeName;
wsCurrent.SaveAs(outputFile, format, Type.Missing, Type.Missing, Type.Missing,
Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing);
however, I found that due to the natural of excel, ince we save the file, it will lock the process until the excel application closed. in other word, I could not load the saved .mht file unless I close excel which I do not want to, any one better idea to do this and please give me a clue to the solution, many thanks in advance, cheers,