Hi, gang.  This should be rather simple.  I have VB code in Access that 
opens an Excel file.  I need the VB code that will close the file.  What is 
happening, is that the Excel file is remaining open after I run the VB 
code.  If, after I run the code in Access, I close Access and go directly 
to the Excel file and open it, I get a prompt saying it is already 
open.   Here's a snippet of my code:

Sub XLTest()
        Dim XL as Object
        Set XL = CreateObject("Excel.Application")
        XL.Workbooks.Open "C:\Import Sales\ToNova.xls"
        XL.Run ("Nova")
End Sub


Thnaks in advance.


Gary



 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ms_access/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to