xlbook.close
        xlApp.Quit
        Set xlSheet = Nothing
        Set xlBook = Nothing
        Set xlApp = Nothing

解决方案 »

  1.   

    Set xlBook = xlApp.Workbooks.Open(strDestination)
      

  2.   

    Public Sub Close_excel()
        If IsNull(objExcel) Then
            Exit Sub
        End If
        objExcel.Close
        MsgBox "closed!"
        Set objExcel = Nothing
    End Sub
    With objExcel
            If .Application.Windows().Count = 1 Then
               .Application.Quit
                   'Excel is already active before this program starts.
            Else
              .Close
            End If
            
            Set objExcel = Nothing
        End With
      

  3.   

    我也碰到了同样的问题,怎么都解决不了,如果找到解决办法请通知一声
    [email protected],   thanksto 寒刃:
    没有看懂你的程序,可否解释一下?
    你的objexcel应该是workbooks对象吧,否则不会有close方法