关闭 excel 2016 后,我一片空白 window?
I get a dead blank window after closing excel 2016?
我的代码 运行 在我关闭工作簿之前都很好。这是我的代码:
.....
With olMail
.Subject = "Hi " & ActiveWorkbook.Name
.Body = strSubject
.Attachments.Add ActiveWorkbook.Path & "\" & ActiveWorkbook.Name
.display
End With
Set olApp = Nothing
Set olNameSpace = Nothing
Set olMail = Nothing
Application.ScreenUpdating = True
ActiveWorkbook.Save
ActiveWorkbook.Saved = True
DoEvents
ActiveWorkbook.Close <<<<===== I see the BLANK EXCEL WINDOW HERE!
Application.EnableEvents = True
Exit Sub
我不确定这是否是 excel 2016 的错误,但这是 excel 的整个 window,缺少功能区:
这是因为您关闭了工作簿而不是应用程序。
使用Application.Quit
我的代码 运行 在我关闭工作簿之前都很好。这是我的代码:
.....
With olMail
.Subject = "Hi " & ActiveWorkbook.Name
.Body = strSubject
.Attachments.Add ActiveWorkbook.Path & "\" & ActiveWorkbook.Name
.display
End With
Set olApp = Nothing
Set olNameSpace = Nothing
Set olMail = Nothing
Application.ScreenUpdating = True
ActiveWorkbook.Save
ActiveWorkbook.Saved = True
DoEvents
ActiveWorkbook.Close <<<<===== I see the BLANK EXCEL WINDOW HERE!
Application.EnableEvents = True
Exit Sub
我不确定这是否是 excel 2016 的错误,但这是 excel 的整个 window,缺少功能区:
这是因为您关闭了工作簿而不是应用程序。
使用Application.Quit