1、打开任务管理,把所有的Excel.exe进程结束;
2、不要打开那个excel,再点击菜单;
3、用try catch处理异常退出的情况
Dim App As New MSExcel.Applicationtry Dim Wb As MSExcel.WorkBook = App.WorkBooks.Open("d:\test.xls") Dim Ws As MSExcel.WorkSheet = Wb.WorkSheets(1) App.Visible = Truecatch ex As Exception msgbox(ex.Message) app.quitEnd try