Just wondering, is there a way to tell access to only display the forms/reports without displaying the access window itself (the "shell" window that the access forms populate inside of).
just wondering.
Just wondering, is there a way to tell access to only display the forms/reports without displaying the access window itself (the "shell" window that the access forms populate inside of).
just wondering.
If you create an MDE and run it under the Access Runtime, it will execute your program stripped of (most, if not all of) the Access GUI.
This is by design. The Access Runtime is intended to allow you to distribute a copy of your application, while depriving your users of the regular Access trappings.
No. Access is a classic Multiple Document Interface (MDI) where all the child windows are inside a parent window.
However, Access does have a lot of ways you can change the Parent Window Menu's and Toolbars. You can create your own menu and toolbar layouts that only have what you want in them. Google creating menu bars and toolbars in Access and it should point you in the right direction.
EDIT:
JP nailed it.... My brain forgot that little nugget....
Yes, you can. See "Setting Startup Options" from Basics for Building Microsoft Office Access 2003 Runtime-Based Solutions.
You can use the Startup dialog box to specify the following:
- Whether or not the Database window should be displayed on startup.
To do so, I take advantage of a piece of code written by some clever guys and available on the net (I think it was originaly written by Terry Kreft?) and refering to some windows API.
I have first this:
Declare Function apiShowWindow Lib "user32" _
Alias "ShowWindow" (ByVal hwnd As Long, _
ByVal nCmdShow As Long) As Long
Global Const SW_HIDE = 0
Global Const SW_SHOWNORMAL = 1
Global Const SW_SHOWMINIMIZED = 2
Global Const SW_SHOWMAXIMIZED = 3
and that
Function fSetAccessWindow(nCmdShow As Long)
'Usage Examples
'Maximize window:
' ?fSetAccessWindow(SW_SHOWMAXIMIZED)
'Minimize window:
' ?fSetAccessWindow(SW_SHOWMINIMIZED)
'Hide window:
' ?fSetAccessWindow(SW_HIDE)
'Normal window:
' ?fSetAccessWindow(SW_SHOWNORMAL)
Dim loX As Long
Dim loForm As Form
On Error Resume Next
Set loForm = Screen.ActiveForm
If Err <> 0 Then 'no Activeform
If nCmdShow = SW_HIDE Then
MsgBox "Cannot hide Access unless a form is on screen"
Else
loX = apiShowWindow(hWndAccessApp, nCmdShow)
Err.Clear
End If
Else
If nCmdShow = SW_SHOWMINIMIZED And loForm.Modal = True Then
MsgBox "Cannot minimize Access with this form on screen:" & (loForm.Caption + " ")
Else
If nCmdShow = SW_HIDE And loForm.PopUp <> True Then
MsgBox "Cannot hide Access with this form on screen:" & (loForm.Caption + " ")
Else
loX = apiShowWindow(hWndAccessApp, nCmdShow)
End If
End If
End If
fSetAccessWindow = (loX <> 0)
End Function
When starting my program, I will then call the function this way
'funtion is called by autoexec Macro'
...
fSetAccessWindow (SW_HIDE)
...
DoCmd.OpenForm my_Startup_Form
Forms(my_Startup_Form).Controls(my_Active_Control).SetFocus
The screen will 'flicker' a little bit, and the main window will appear briefly, then disappear. My focussed window will then be displayed alone.