I tried other ways of closing it, but it is still in the Tast Manager ...
It opens it up and that's it ... how the hell do I close it
I use Microsoft Excel 11.0 Lib.
here is the code
VB Code:
Public Sub Check_Validity2() On Error GoTo NoFile Set myBook = Workbooks.Open(strMainFilePath) exists = myBook.Worksheets("AH Data").Cells(1, 3).Value If exists = "AH1 (AH09-01)" Then exists = "true" Else: exists = "" End If myBook.Close savechanges:=False NoFile: If Err.Number = 9 Then myBook.Close exists = "" End If End Sub




Reply With Quote