Minimize Database

  • Thread starter Thread starter karen gregg
  • Start date Start date
K

karen gregg

I have pop up and modal set to "yes" on my form. To change
them to "NO" is not an option. The user wishes to be able
to access other applications which they may not have
already opened prior to opening the database hence the
toggle between applications is not an option. I have the
coding to minimize the database but this does not work
with pop up and modal set to "yes". Is there a way to
minimize the database whilst still having pop up and modal
set to yes on the form ?

TIA
 
Hi Karen

Microsoft article Q148834 seems to summarize this quite well. In case you have
difficulty finding the article here it is:

Hope this helps

Best regards

Maurice St-Cyr

-----------------------------------------

SUMMARY
=======

Advanced: Requires expert coding, interoperability, and multiuser skills.

Microsoft Access does not provide a function to maximize, minimize, and
restore Microsoft Access from a module or macro. This article demonstrates
how to use Microsoft Windows API calls in code to maximize, minimize, and

restore Microsoft Access.

This article assumes that you are familiar with Visual Basic for
Applications and with creating Microsoft Access applications using the
programming tools provided with Microsoft Access. For more information
about Visual Basic for Applications, please refer to your version of
the "Building Applications with Microsoft Access" manual.

MORE INFORMATION
================

Once you define the following sample functions in a module, you can use

them in macros as RunCode actions. To do so, follow these steps:

1. On the Insert menu, click New, and then Module. Type the following lines
in the Declarations section:

Option Explicit

Global Const SW_SHOWNORMAL = 1
Global Const SW_SHOWMINIMIZED = 2
Global Const SW_SHOWMAXIMIZED = 3

Declare Function ShowWindow Lib "User32" (ByVal Hwnd As Long, _
ByVal nCmdShow As Long) As Long

2. Create the function MaximizeAccess():

Function MaximizeAccess()
Dim Maxit%
Maxit% = ShowWindow(hWndAccessApp, SW_SHOWMAXIMIZED)
End Function

3. Create the function MinimizeAccess():

Function MinimizeAccess()
Dim Minit%
Minit% = ShowWindow(hWndAccessApp, SW_SHOWMINIMIZED)
End Function

4. Create the function RestoreAccess():

Function RestoreAccess()
Dim Restoreit%
Restoreit% = ShowWindow(hWndAccessApp, SW_SHOWNORMAL)

End Function

5. The following sample macro action will minimize the Microsoft Access
window:

Action FunctionName
 
Back
Top