Problem with opening excel

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I’m having problems getting the programming correct using an Access Form as a
front end to open an Excel Workbook. The workbook is already is in place, but
the customer wants Access for the front end.
My problem is I can’t figure out how to set the "on open properties" for the
workbook.
I need to have the have a worksheet open maximized, and I want to hide all
toolbars.

Below is the code I have set to call Excel.




Private Sub Command0_Click()

Dim xlApp As Object
Dim FleNme As String
FleNme = "L:OFFICE SKILLS\FRONT END - DATA ENTRY.xls"
Set xlApp = CreateObject("Excel.Application")
SendKeys "{LEFT}{ENTER}"
'xlApp.Open "L:OFFICE SKILLS\FRONT END - DATA ENTRY.xls"
Set xlApp = Nothing ' set the reference to nothing

End Sub
 
Send Keys is too unpredictable. Here's a couple of ways.

http://groups.google.co.uk/groups?h...m=#[email protected]#link1


Ask them here about programmatically removing the toolbars for the active
workbook.

http://www.microsoft.com/communitie...890-3454-4fc6-b99f-9f2e75f4da08&lang=en&cr=US
--
Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

:
| I'm having problems getting the programming correct using an Access Form
as a
| front end to open an Excel Workbook. The workbook is already is in place,
but
| the customer wants Access for the front end.
| My problem is I can't figure out how to set the "on open properties" for
the
| workbook.
| I need to have the have a worksheet open maximized, and I want to hide all
| toolbars.
|
| Below is the code I have set to call Excel.
|
|
|
|
| Private Sub Command0_Click()
|
| Dim xlApp As Object
| Dim FleNme As String
| FleNme = "L:OFFICE SKILLS\FRONT END - DATA ENTRY.xls"
| Set xlApp = CreateObject("Excel.Application")
| SendKeys "{LEFT}{ENTER}"
| 'xlApp.Open "L:OFFICE SKILLS\FRONT END - DATA ENTRY.xls"
| Set xlApp = Nothing ' set the reference to nothing
|
| End Sub
 
Back
Top