Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

opening an excel file from access

Status
Not open for further replies.

St0rm

MIS
Oct 19, 2000
23
0
0
GB
I have look thought the old threads and can not find the answer.

I have a form and when i click a button i need it to open an excel file.

the closes i have got is :-

Set oApp = CreateObject("Excel.Application")
oApp.Visible = True
On Error Resume Next
oApp.UserControl = True

but this will not open a file just opens excel.
 
Try adding the following line to your code where fname is the name and path of the file you wish to open.

oApp.Workbooks.Open fname
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top