作者:乔山办公网日期:
返回目录:excel表格制作
Sub fasdf()
Dim wb As Object
For Each wb In Workbooks
If wb.Name <> ThisWorkbook.Name Then
wb.Close True
End If
Next
ThisWorkbook.Close True
End Sub
如果a是百b通过vba调用excel application打开的, 那代码关闭它很度容易
如果不是问, 那需要调用windows API遍历答目前所有进程, 然后专判断哪个excel进程是需要关属闭的, 关闭即可
1 你将计算方式 改为手动
2 检查你的表中公式计算是否优化
3 优化你的函数
请问Workbooks("test.xlsm")和ThisWorkbook是否为同一个对象?