open excel

G

Gerald Stanley

1. You need to create an Excel Application object e.g.

Dim xlApp As Excel.Application
Set xlApp = CreateObject("Excel.Application")

2. To open a particular workbook, you need to use the Open
method of the Workbooks Collection e.g.

Dim xlBook As Excel.Workbook
Set xlBook = xlApp.Workbooks.Open {filename}

The {filename} needs to be replaced with the file of your
choice with the full path.

Don't forget to include the Excel Object librarry wthin the
References.

Hope This Helps
Gerald Stanley MCSD
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top