ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Automating MS-Access DB to open correctly (https://www.excelbanter.com/excel-programming/385420-automating-ms-access-db-open-correctly.html)

XP

Automating MS-Access DB to open correctly
 
Using Office 2003 and Windows XP.

I have a loading program that is designed to open an Access DB and then
Excel closes itself. It works, but when Access opens, the initial window is
small, then it maximizes, but the Main Menu remains the size of the small
window that initially opened.

So every time this runs, the users will have to resize this tiny menu so
they can see everything.

Does anyone have a clue how to fix this?

My code:

Dim oAccessApp As Object
Set oAccessApp = GetObject(csFullNameDestin, "Access.Application")
oAccessApp.Visible = True
oAccessApp.DoCmd.RunCommand 10 '10 = acCmdAppMaximize

Thanks much.

Madhan

Automating MS-Access DB to open correctly
 
Hi, you can try the following snippet, Shell "C:\Program Files\Microsoft
Office\OFFICE11\MSACCESS.EXE" & Your filename.
I hope this helps you.

"XP" wrote:

Using Office 2003 and Windows XP.

I have a loading program that is designed to open an Access DB and then
Excel closes itself. It works, but when Access opens, the initial window is
small, then it maximizes, but the Main Menu remains the size of the small
window that initially opened.

So every time this runs, the users will have to resize this tiny menu so
they can see everything.

Does anyone have a clue how to fix this?

My code:

Dim oAccessApp As Object
Set oAccessApp = GetObject(csFullNameDestin, "Access.Application")
oAccessApp.Visible = True
oAccessApp.DoCmd.RunCommand 10 '10 = acCmdAppMaximize

Thanks much.



All times are GMT +1. The time now is 05:04 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com